Water network system model construction method, computer equipment and storage medium
By deconstructing the water network system into control objects and controlled objects, and using a graphical modeling method to automatically generate mathematical models, the problem of low efficiency and poor flexibility in water network model construction in existing technologies is solved, and efficient and flexible water network model construction and popularization are realized.
Patent Information
- Application Number
- CN202610113801.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-01-28
- Publication Date
- 2026-03-03
AI Technical Summary
Existing technologies suffer from problems such as long development cycles, high labor costs, difficulty in porting and reusing, poor model maintainability, and high technical barriers when constructing complex water network models. The lack of a unified modeling theory and deep coupling result in extremely poor model flexibility and scalability.
By employing physical element deconstruction and cybernetics classification, the water network system is deconstructed into controlled objects and controlled objects. Standardized software object templates are created, and mathematical model equations are automatically generated through graphical topology construction and system model generation.
It achieves universality and standardization in modeling, improves modeling efficiency and flexibility, lowers the technical threshold, and enables non-computer programming experts to quickly build complex models, thus promoting the popularization and application of modeling technology.
Smart Images

Figure CN121598547A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the fields of water resources system engineering and computer information technology, and specifically relates to a method for constructing a water network system model, computer equipment, and storage medium. Background Technology
[0002] Water network systems are critical infrastructure for ensuring socio-economic development and ecological security. To achieve refined and intelligent management of water networks, constructing mathematical models that accurately describe their physical behavior is a core prerequisite. However, existing technologies generally face the following technical bottlenecks when constructing complex water network models:
[0003] 1. "Handicraft" Development Model: Traditional water network modeling heavily relies on the personal experience and programming skills of modeling experts. For each new water network project, customized code needs to be written from scratch, "hard-coding" the topological relationships, hydraulic constraints, and operational objectives of the physical water network into the program. This model is like a "handicraft workshop," with long development cycles, high labor costs, and results that are difficult to transfer and reuse.
[0004] 2. Lack of a unified modeling theory: Due to the diverse physical forms of water network systems, including various elements such as rivers, canals, pipe networks, reservoirs, sluice gates, and pumping stations, the industry has long lacked a universal "grammar" or theoretical framework that can uniformly describe these heterogeneous elements. This has directly led to a "case-by-case" approach to model development, making it impossible to form standardized and accumulative modeling assets.
[0005] 3. Deep coupling between model and topology: In existing technologies, the mathematical equations of the model are deeply coupled with the physical topology of the water network it describes. Once the topology of the water network changes (such as adding a pumping station or abandoning a section of the canal), it often means that the underlying code of the entire model needs to be modified and recompiled extensively or even radically, resulting in extremely poor maintainability, flexibility and scalability of the model.
[0006] 4. High technical threshold and difficulty in promotion: The complex modeling process requires modelers to be proficient in water conservancy knowledge and have superb computer programming and numerical calculation skills. The scarcity of such compound talents greatly restricts the widespread application and industrialization of advanced modeling technology.
[0007] Therefore, how to completely transform the current "manual workshop" model of water network modeling and provide a universal, efficient, and automated method for building water network system models is a technical problem that urgently needs to be solved in this field.
[0008] The information disclosed in this background section is intended only to enhance the understanding of the overall background of the invention and should not be construed as an admission or in any way implying that the information constitutes prior art known to those skilled in the art. Summary of the Invention
[0009] The purpose of this invention is to solve the problems existing in the prior art and to provide a method for constructing a water network system model, a computer device, and a storage medium.
[0010] The first aspect of this invention provides a method for constructing a water network system model, comprising the following steps: S1. Physical element deconstruction and cybernetics classification: The physical water network system to be modeled is deconstructed into discrete physical elements, and the physical elements are classified into categories to obtain the target object. S2. Standardized object encapsulation: Create standardized software object templates for the target object to form a standard object library; S3. Graphical Topology Construction: Construct a directed graph representing the topology of the physical water network system; S4. System Model Generation: Based on the directed graph, a set of mathematical model equations describing the dynamic behavior of the entire physical water network system is obtained.
[0011] In one embodiment of the present invention, the target object includes: a control object and a controlled object. The controlled object is a physical element that actively exerts control over the physical water network system and changes the system state. It has externally set control variables, which include at least one of the following variables: gate opening degree, pump speed, number of operating pumps, and generator output. The controlled objects include at least one of the following: gate stations, pumping stations, valves, hydropower station units, flood discharge facilities, and rubber dams; The controlled object is a passive physical element that is affected by the control action and exhibits inertial or time-delay characteristics. It has state variables describing its state, and the state variables include at least one of the following variables: water level, storage capacity, and flow rate. The controlled object includes at least one of the following: river section, canal section, pipeline section, reservoir, and lake.
[0012] In one embodiment of the present invention, each software object template encapsulates the intrinsic attributes, mathematical descriptions (i.e., internal constraint equations), and physical constraints of its corresponding physical element.
[0013] In one embodiment of the present invention, the standard object library includes controlled object templates and control object templates.
[0014] In one embodiment of the present invention, the controlled object template includes at least one of the following templates: Reservoir or Lake Object Template: Encapsulates the differential equations describing the dynamic balance of water volume in a reservoir or lake, including its core internal constraint equations. , In the above formula, Represents time, in seconds; It is the water storage capacity of a reservoir or lake, a state variable, and its unit is cubic meters; It is the total inflow of water into a reservoir or lake, expressed in cubic meters per second. It is the total outflow from a reservoir or lake, expressed in cubic meters per second. This includes losses from evaporation and infiltration, measured in cubic meters per second. Additionally, the reservoir or lake object template also encapsulates the water level, describing its geometric characteristics. - Storage capacity relation: , Among them, the water level - Storage capacity The fitting equation for the relationship is as follows: , , in, , , , , , Represents the coefficients of the fitted equation. Indicates the minimum control water level. For index; River or Open Channel Object Template: Encapsulates a set of partial differential equations or equations describing the unsteady flow evolution of a river or open channel, including: For operating conditions requiring hydrodynamic simulation, encapsulate the equation set: , , in, The cross-sectional area of a river or open channel, expressed in square meters. The flow rate of a river or open channel, expressed in cubic meters per second; The distance along the course of a river or open channel, in meters; The flow rate is the side flow of a river or open channel, measured in cubic meters per second. The water level in a river or open channel, in meters; It is an energy gradient, dimensionless; The slope of the canal bottom is dimensionless; It is the acceleration due to gravity, measured in meters per second squared. For scenarios including hydrological forecasting, time After discretizing to time points, encapsulate the system of equations: , , , , , in, Indicates at a point in time Downstream outflow rate of a river or open channel, expressed in cubic meters per second; Indicates a point in time The upstream inflow rate of a river or open channel, expressed in cubic meters per second; Indicates the previous time point The upstream inflow rate of a river or open channel, expressed in cubic meters per second; Indicates the previous time point Downstream outflow rate of a river or open channel, expressed in cubic meters per second; Indicates the time step, in seconds; The flow proportion coefficient reflects the relative weight of the total water storage capacity of a river or open channel due to the influence of upstream inflow and downstream outflow, and is dimensionless. This represents the storage coefficient, and its dimension is time (seconds). , , This is the Musking coefficient.
[0015] In one embodiment of the present invention, the controlled object template includes at least one of the following templates: Control gate object template: Encapsulates the algebraic equations describing the current-carrying capacity of the control gate, with its core internal constraint formulas as follows: (1) in, This is the flow rate through the gate, measured in cubic meters per second. It is the flow rate coefficient, and the unit is the number of cubic meters flowing through the control gate per hour; This refers to the gate width, in meters. It is the acceleration due to gravity, measured in meters per second squared. and These are the water levels before and after the sluice gate, respectively, in meters; and This refers to the gate opening, measured in meters. Water diversion gate object template: The internal constraints of the water diversion gate are a set of... A system of equations consisting of equations, where the number of equations is 1. Let be the total number of downstream branches, and be a positive integer. Each downstream branch has a gate, and each equation describes the flow rate through the gate at the corresponding branch outlet: , ,
[0016] , in: Is flowing to the first The instantaneous flow rate of each downstream branch, in cubic meters per second. Integer and ; It is the first The gate is the first one. The opening degree of the gates on each downstream branch, in meters; This is the common upstream water level for all sluice gates, expressed in meters. It is the first The water level in the downstream branch canal / pipe, function It is an overcurrent formula; Pump station object template: Encapsulates the characteristic curve equations describing the performance of the pump station; its core internal constraint is the head-flow rate relationship. , The head-flow rate relationship is expressed as a function of the flow rate through the pumping station. The quadratic polynomial: , Among them, the pump station head The value is determined by the difference in water levels between the upstream and downstream sections it connects to, and the unit is meters. It is the instantaneous flow rate through the pumping station, measured in cubic meters per second, while the coefficient... , , Based on the water pump speed The decision is made regarding the water pump speed. The unit is revolutions per minute; Pipeline Valve Object Template: The core internal constraints of pipeline valves describe the instantaneous flow rate through the pipeline valve. Pressure difference between the two ends of the pipeline valve With pipeline valve opening Algebraic equations relating them: , in: It is the instantaneous flow rate through the pipeline valve, measured in cubic meters per second; It is the pressure difference between the upstream and downstream of a pipeline valve, measured in Pascals, and determined by the state of the upstream and downstream pipeline objects it is connected to. It is the flow coefficient of the pipeline valve, which is dimensionless; It is a unit conversion constant; Specific gravity of a fluid, dimensionless; Hydropower Unit Object Template: The core internal constraint of a hydropower unit is the equation: , in, It is the instantaneous power generation of the hydroelectric generator unit, measured in watts; It is the density of water, measured in kilograms per cubic meter. The flow rate through the hydroelectric generator unit is expressed in cubic meters per second. It is the net working head of the hydropower unit, measured in meters, and is determined by the water level difference between the upstream and downstream reservoirs or rivers to which it is connected. It is the overall efficiency of the unit, which is a non-linear function defined by a set of comprehensive characteristic curves or Hill diagrams.
[0017] In one embodiment of the present invention, step S3 includes: on the graphical user interface, in response to the user's drag and connect operations, instantiating the corresponding software object from the standard object library, and constructing a directed graph representing the topology of the physical water network system based on the actual connection relationship of the physical water network. The directed graph includes: Node: Each node in the directed graph is a software object instance, which encapsulates all the physical parameters and internal constraint equations of the corresponding object; Directed edges: Directed edges connecting the nodes represent the hydraulic connections between the software object instances, specifying the upstream and downstream locations and the direction of water flow. The nodes and directed edges constitute the directed graph.
[0018] In one embodiment of the present invention, step S4 includes: traversing the directed graph and performing the following steps: Extracting internal constraints: Extract the encapsulated internal constraint equations from each node of the directed graph; Generate coupling constraints: Based on the connection relationships between nodes in the directed graph, automatically generate coupling constraint equations describing the hydraulic connections between objects; Integrating to form a system model: combining all the extracted internal constraint equations and all the generated coupling constraint equations to form a set of mathematical model equations describing the dynamic behavior of the entire physical water network system.
[0019] A second aspect of the present invention provides a computer device including a memory, a first processor, and a first computer program stored in the memory and executable on the first processor, wherein the first computer program, when executed by the first processor, implements the above-described method for constructing a water network system model.
[0020] A third aspect of the present invention provides a computer-readable storage medium for storing a second computer program, which can be executed by at least one second processor to perform the above-described water network system model construction method.
[0021] Compared with the prior art, the technical effects achieved by the present invention are as follows: 1. It achieves the universality and standardization of modeling.
[0022] The "control-controlled object" classification method proposed in this invention is an original and universally applicable unified modeling theory. It provides a standard "syntax" for describing complex water networks of arbitrary shapes, fundamentally solving the problem of "case-by-case" modeling caused by the lack of a unified theory.
[0023] 2. It has achieved a high degree of automation and efficiency improvement in the modeling process.
[0024] By constructing topology through a graphical "building block" approach and automatically generating a complete mathematical model, the traditional tedious and error-prone manual coding process has been completely replaced. This reduces the model construction time from months to days or even hours, greatly improving development efficiency.
[0025] 3. It achieves a high degree of decoupling and flexibility in the model.
[0026] This invention completely separates the "characteristic description of the physical element itself" (encapsulated inside the object) from the "connection relationship description between elements" (reflected in the topology diagram). When the water network topology changes, the user only needs to modify the connection on the graphical interface, and the model can be automatically regenerated without modifying the underlying code, which greatly enhances the flexibility, maintainability and scalability of the model.
[0027] 4. Significantly reduced the technical threshold.
[0028] The graphical and intuitive modeling method adopted in this invention enables water conservancy experts who are not proficient in computer programming to quickly and accurately construct professional and complex mathematical models, which greatly promotes the popularization and application of advanced modeling technology. Attached Figure Description
[0029] Figure 1 This is a flowchart of a water network system model construction method according to an embodiment of the present invention. Detailed Implementation
[0030] Unless otherwise expressly stated, throughout the specification and claims, the term "comprising" or its variations such as "including" or "comprises" shall be understood to include the stated elements or components without excluding other elements or other components.
[0031] The technical solution of the present invention is illustrated below through specific embodiments. It should be understood that the one or more steps mentioned in the present invention do not preclude the existence of other methods and steps before or after the combined steps, or that other methods and steps may be inserted between these explicitly mentioned steps. It should also be understood that these examples are for illustrative purposes only and are not intended to limit the scope of the present invention. Unless otherwise stated, the numbering of each method step is only for the purpose of identifying each method step, and not for limiting the order of each method or limiting the scope of the present invention. Changes or adjustments to their relative relationships, without substantial changes to the technical content, can also be considered as within the scope of the present invention.
[0032] The raw materials and instruments used in the examples are not subject to any specific restrictions on their source; they can be purchased from the market or prepared according to conventional methods known to those skilled in the art.
[0033] Figure 1 This is a flowchart of the water network system model construction method provided by the present invention. Figure 1 As shown, the water network system model construction method according to a preferred embodiment of the present invention includes the following steps.
[0034] S1. Physical Element Deconstruction and Cybernetics Classification. This involves deconstructing the physical water network system to be modeled into a set of discrete physical elements, and classifying these physical elements into at least two of the following categories: Controlling Object: Defined as a physical element capable of actively exerting control over a water network system and changing its state. It is characterized by having externally set control variables such as gate opening, pump speed, number of operating pumps, and generator output. The controlling object includes, but is not limited to: gate stations, pumping stations, valves, hydropower station units, flood discharge facilities, and rubber dams.
[0035] Controlled Object: Defined as a passive physical element that is affected by the control and exhibits inertial or time-delay characteristics, characterized by having state variables describing its state, such as water level, storage capacity, and flow rate. The controlled object includes, but is not limited to, river sections, canal sections, pipeline sections, reservoirs, and lakes.
[0036] S2. Standardized Object Encapsulation. This involves creating standardized software object templates for both the controlled object and the controlled object, forming a reusable standard object library. Each software object template encapsulates the inherent attributes, mathematical description (i.e., internal constraint equations), and physical constraints of its corresponding physical elements. The standard object library may include the following templates: S21. Controlled Object Templates, including: S21a, Reservoir or Lake Object Template: Encapsulates the differential equations describing the dynamic balance of water volume in a reservoir or lake. The core internal constraint equations of this template are: , In the above formula, Represents time, in seconds ( ); It refers to the water storage capacity of a reservoir or lake, which is a state variable, and its unit is cubic meters (m³). ); It is the total inflow of water into a reservoir or lake, expressed in cubic meters per second. ); It is the total outflow from a reservoir or lake, in units of... ; This refers to losses such as evaporation and seepage, expressed in units of... Additionally, the template also encapsulates the water level, which describes its geometric properties. - Storage capacity Curve or relationship: , Among them, water level - Storage capacity The fitting equation for the relationship is as follows: , , In the two equations above: , , , , , Represents the coefficients of the fitted equation. This indicates the minimum control water level, which is determined by technicians based on the operating conditions. The data is obtained by fitting the exponential data based on specific working conditions.
[0037] S21b, River or Open Channel Object Template: Encapsulates a set of partial differential equations or equations describing the unsteady flow evolution of a river or open channel, including: For operating conditions requiring hydrodynamic simulation, encapsulate the equation set: , , In the two equations above, The cross-sectional area of a river or open channel refers to the area actually occupied by water flow at a specific cross-section of the river, canal, or pipe, measured in square meters. ); The flow rate of a river or open channel, in units of ; The distance along a river or open channel, that is, the distance measured along the path of water flow (such as the centerline of a river, canal, or pipe), is measured in meters (m). ); Side inflow refers to the flow of water entering (i.e., merging into) the main flow from both sides of a river or open channel along its path. The unit is liters. ; Water level in rivers or open channels, in units of ; It is an energy gradient, dimensionless; The slope of the canal bottom is dimensionless.
[0038] For scenarios such as hydrological forecasting, time After discretizing into a series of time points with equal time intervals and these intervals being sufficiently small (i.e., less than the expected threshold), a system of equations can be encapsulated: , , , , , in, Indicates at a point in time The downstream outflow of a river or open channel is a predicted value calculated by the model, in units of... ; Indicates a point in time Upstream inflow of a river or open channel, in units of ; Indicates the previous time point Upstream inflow of a river or open channel, in units of ; Indicates the previous time point Downstream outflow of a river or open channel, in units of ; This indicates the time step, i.e., the time interval, in seconds. ); The flow proportion coefficient reflects the relative weight of the total water storage capacity of a river or open channel due to the influence of upstream inflow and downstream outflow, and is dimensionless. The storage coefficient is expressed in units of time (seconds) and is approximately equal to the propagation time required for a flood wave to pass through a section of the river under study. , , This is the Musking coefficient.
[0039] S22. Controlling Object Templates, including: S22a, Control Gate (a hydraulic structure installed on a canal or river to actively control upstream water level and downstream flow by adjusting its opening) object template: Encapsulates the algebraic equations describing the control gate's flow capacity. Its core internal constraint formulas are as follows: (1) In the above formula, It is the flow rate through the gate, in units of ; It is the gate flow coefficient, which is the number of cubic meters flowing through the control gate per hour; It is the gate width, in units of ; It is the acceleration due to gravity, measured in meters per second squared (m²). ); and These refer to the water levels upstream and downstream of the sluice gate, respectively. In the case of free outflow, the following settings can be established: Always equal to 0, unit is ;and It is an externally adjustable control variable—the gate opening, measured in units of... .
[0040] S22b, Diversion Gate (a "water distributor" installed at the bifurcation of a channel, whose core function is to control the amount and proportion of water flowing into each branch canal) object template: The internal constraints of the diversion gate are a set of... A system of equations consisting of several equations, each describing the flow rate through the corresponding diversion outlet. The form of these equations is consistent with the internal constraint equations of the control gate object template, i.e., the submerged orifice flow or weir flow formula. The number of equations in the system is... The total number of downstream branches is a positive integer, and each downstream branch has a gate.
[0041] , ,
[0042] , In the above system of equations: Is flowing to the first The instantaneous flow rate of each downstream branch, in units of ; It is the first The gate is the first one. The opening degree of the gate on each downstream branch (one of the control variables in this group), in units of ; This is the upstream water level common to all sluice gates, in units of... ; It is the first Water level in the downstream branch canal / pipe. Function It is a current flow formula, such as equation (1). Wherein, It is an integer and .
[0043] S22c, Pumping Station Object (with the core function of forcibly increasing energy by pumping water to achieve water lifting from low-lying areas or pressurizing water for long-distance transport). Template: Encapsulates the characteristic curve equations describing the pumping station's performance; its core internal constraint is the head-flow rate relationship. , The above formula represents the flow rate through the pumping station. The quadratic polynomial: , In the above formula, the pump station head The unit is determined by the difference in water levels between the upstream and downstream sections it connects to. ; It is the instantaneous flow rate through the pumping station, in units of ;coefficient , , Then the technicians will determine the control variable—the pump speed. (When the pump stops, the pump speed) The pump speed is determined by a value of 0. The unit is revolutions per minute.
[0044] S22d, Pipeline valve (a core control element installed in a closed piping system, used to cut off, connect, and regulate the flow and pressure of fluids within the pipe) object template: The core internal constraint of the pipeline valve describes the instantaneous flow rate through the pipeline valve. Pressure difference between the two ends of the pipeline valve With pipeline valve opening An algebraic equation relating the two. In engineering practice, the following formula is used to describe the relationship. : , In the above formula, It is the instantaneous flow rate through the pipeline valve, and the unit is... ; It is the pressure difference between the upstream and downstream sides of a pipeline valve, measured in Pascals (Pa). Pa (This is determined by the state of the upstream and downstream pipeline objects it is connected to;) It is the flow coefficient of the pipeline valve, which is a controlled variable. The nonlinear function, the relationship between which is the characteristic curve of the pipeline valve, is encapsulated inside the template, and the coefficient is dimensionless. It is a unit conversion constant; It is the specific gravity of the fluid, dimensionless.
[0045] S22e, Hydropower Unit (the core equipment in a hydropower station that generates electricity by utilizing the water head impacting the turbine, and also has the important function of rapidly regulating the power grid (peak shaving and frequency regulation)) Object Template: The core internal constraint of the hydropower unit is to describe its instantaneous power generation. Traffic Clean working head Overall unit efficiency The equation relating them is: , In the above formula, It is the instantaneous power generation of a hydroelectric generator, measured in watts (W). ); It is the density of water, measured in kilograms per cubic meter. The flow rate through the hydroelectric generator unit is expressed in units of... ; It is the net working head of the unit, in units of It is determined by the water level difference between the upstream and downstream reservoirs or rivers it connects to; It is the overall efficiency of the unit, which is a key, non-linear function whose value depends on the control variables. and system state variables This function is usually defined by a set of "comprehensive characteristic curves" or Hill plots, and can be encapsulated within the template through methods such as table lookup, interpolation, or polynomial fitting.
[0046] S3, graphical topology construction.
[0047] On the graphical user interface (GUI), in response to user drag-and-drop and connection operations, corresponding software objects are instantiated from the standard object library, and a directed graph representing the topology of the water network system is constructed based on the actual connection relationships of the physical water network, including the following steps: S31. The user drags icons representing various physical elements, such as reservoirs, sluice gates, and pumping stations, from a toolbox containing all standardized object templates onto the modeling canvas. For each icon dragged, a corresponding software object with independent parameter configurations is instantiated in the background.
[0048] S32. Users define the physical connections between object instances by drawing connecting lines. Correspondingly, the backend constructs a structured directed graph, which includes: Nodes: Each node in the graph is a software object instance, which encapsulates all the physical parameters and internal constraint equations of the corresponding object.
[0049] Directed Edges: Directed edges that connect nodes represent the hydraulic connections between instances, specifying the upstream and downstream orientation and the direction of water flow.
[0050] The directed graph, consisting of nodes and directed edges, completely and accurately describes the topology of the physical water network, providing a machine-readable data foundation for the automatic generation of the model in the next step.
[0051] S4, System Model Generation.
[0052] Traverse the directed graph and perform the following steps: S41. Extract internal constraints: Extract the encapsulated internal constraint equations from each node (i.e., software object instance) of the directed graph.
[0053] S42. Generate Coupling Constraints: Based on the connection relationships (i.e., directed edges) between nodes in the directed graph, automatically generate coupling constraint equations describing the hydraulic connections between objects. These coupling constraint equations are primarily based on the principles of water balance and water level continuity at physical connection points. For the first... 1 node For positive integers, the water balance equation can be expressed as: , in, This means that at any given moment, from the first... The node flows into the first Traffic per node, in units of , It is a positive integer and is different from ; This means that at any given moment, from the first... The node flows into the first Traffic per node, in units of , It is a positive integer and is different from ; It is all for the first A set of nodes with inflow behavior; It is the first The set of all nodes to which a node has inflow behavior. The above formula shows that all inflows to the nth node... The sum of the flows at each node must equal the sum of all flows out of that node. Also, for continuous water levels, the... The water level at each node is unique; for example, the water level upstream of the control gate. equal to the water level of the reservoir : = .
[0054] S43. Integrating to Form a System Model: Combine all extracted internal constraint equations and all generated coupling constraint equations to form a complete and solvable mathematical model equation system describing the dynamic behavior of the entire physical water network system. The final system model is a large-scale differential-algebraic equation system (DAE), whose general form can be expressed as: , In the above formula: It is the state variable vector of the water network system, such as the storage capacity of all reservoirs and the water level of each section of the river. It is the derivative of the state variable with respect to time; It is the algebraic variable vector of the system, referring to the intermediate physical quantities in the system that do not contain time derivative terms and are constrained by algebraic equations. Specifically, it includes: the instantaneous flow rate through each controlled object (gate, pump, valve), the head difference or pressure difference between each node, and the instantaneous power generation of the hydropower unit. These are the system's control variable vectors, such as the opening degree of all gates and the speed of the water pump. This set of equations can be directly fed into a numerical solver for simulation, prediction, or optimization calculations.
[0055] The present invention also provides a computer device, which includes a memory, a first processor, and a first computer program stored in the memory and executable on the first processor. When the first computer program is executed by the first processor, it implements the above-described method for constructing a water network system model.
[0056] The present invention also provides a computer-readable storage medium for storing a second computer program, which can be executed by at least one second processor to enable the at least one second processor to perform the above-described water network system model construction method.
[0057] The "control-controlled object" classification method proposed in this invention is an original and universally applicable unified modeling theory. It provides a standard "syntax" for describing complex water networks of arbitrary shapes, fundamentally solving the "case-by-case" modeling problem caused by the lack of a unified theory. This invention constructs the topology through a graphical "building block" approach, and the system automatically generates a complete mathematical model, completely replacing the traditional tedious and error-prone manual coding process. This reduces model construction time from months to days or even hours, greatly improving development efficiency. The invention completely separates the "description of the physical elements' own characteristics" (encapsulated within the object) from the "description of the connection relationships between elements" (represented in the topology diagram). When the water network topology changes, users only need to modify the connections in the graphical interface, and the model can be automatically regenerated without modifying the underlying code, greatly enhancing the model's flexibility, maintainability, and scalability. The graphical and intuitive modeling method adopted in this invention enables water conservancy experts who are not proficient in computer programming to quickly and accurately construct professional and complex mathematical models, greatly promoting the popularization and application of advanced modeling technologies.
[0058] The foregoing description of specific exemplary embodiments of the invention is for illustrative and explanatory purposes. These descriptions are not intended to limit the invention to the precise forms disclosed, and it will be apparent that many changes and variations can be made in accordance with the foregoing teachings. The exemplary embodiments were chosen and described in order to explain the specific principles of the invention and its practical application, thereby enabling those skilled in the art to implement and utilize various different exemplary embodiments of the invention, as well as various different choices and variations. The scope of the invention is intended to be defined by the claims and their equivalents.
Claims
1. A method for constructing a water network system model, characterized in that, Including the following steps: S1. Physical element deconstruction and cybernetics classification: The physical water network system to be modeled is deconstructed into discrete physical elements, and the physical elements are classified into categories to obtain the target object. S2. Standardized object encapsulation: Create standardized software object templates for the target object to form a standard object library; S3. Graphical Topology Construction: Construct a directed graph representing the topology of the physical water network system; S4. System Model Generation: Based on the directed graph, a set of mathematical model equations describing the dynamic behavior of the entire physical water network system is obtained.
2. The method for constructing a water network system model according to claim 1, characterized in that, The target objects include: the controlling object and the controlled object. The controlled object is a physical element that actively exerts control over the physical water network system and changes the system state. It has externally set control variables, which include at least one of the following variables: gate opening degree, pump speed, number of operating pumps, and generator output. The controlled objects include at least one of the following: gate stations, pumping stations, valves, hydropower station units, flood discharge facilities, and rubber dams; The controlled object is a passive physical element that is affected by the control action and exhibits inertial or time-delay characteristics. It has state variables describing its state, and the state variables include at least one of the following variables: water level, storage capacity, and flow rate. The controlled object includes at least one of the following: river section, canal section, pipeline section, reservoir, and lake.
3. The method for constructing a water network system model according to claim 2, characterized in that, Each of the software object templates encapsulates the internal constraint equations and physical constraints of its corresponding physical elements.
4. The method for constructing a water network system model according to claim 3, characterized in that, The standard object library includes controlled object templates and control object templates.
5. The method for constructing a water network system model according to claim 4, characterized in that, The controlled object template includes at least one of the following templates: Reservoir or Lake Object Template: Encapsulates the differential equations describing the dynamic balance of water volume in a reservoir or lake, including its core internal constraint equations. , In the above formula, Represents time, in seconds; It is the water storage capacity of a reservoir or lake, a state variable, and its unit is cubic meters; It is the total inflow of water into a reservoir or lake, expressed in cubic meters per second. It is the total outflow from a reservoir or lake, expressed in cubic meters per second. This includes losses from evaporation and infiltration, measured in cubic meters per second. Additionally, the reservoir or lake object template also encapsulates the water level, describing its geometric characteristics. - Storage capacity relation: , Among them, the water level - Storage capacity The fitting equation for the relationship is as follows: , , in, , , , , , The coefficients of the fitted equation are represented. Indicates the minimum control water level. For index; River or Open Channel Object Template: Encapsulates a set of partial differential equations or equations describing the unsteady flow evolution of a river or open channel, including: For operating conditions requiring hydrodynamic simulation, encapsulate the equation set: , , in, The cross-sectional area of a river or open channel, expressed in square meters. The flow rate of a river or open channel, expressed in cubic meters per second; The distance along the course of a river or open channel, in meters; The flow rate is the side flow of a river or open channel, measured in cubic meters per second. The water level in a river or open channel, in meters; It is an energy gradient, dimensionless; The slope of the canal bottom is dimensionless; It is the acceleration due to gravity, measured in meters per second squared. For scenarios including hydrological forecasting, time After discretizing to time points, encapsulate the system of equations: , , , , , in, Indicates at a point in time Downstream outflow rate of a river or open channel, expressed in cubic meters per second; Indicates a point in time The upstream inflow rate of a river or open channel, expressed in cubic meters per second; Indicates the previous time point The upstream inflow rate of a river or open channel, expressed in cubic meters per second; Indicates the previous time point Downstream outflow rate of a river or open channel, expressed in cubic meters per second; Indicates the time step, in seconds; The flow proportion coefficient reflects the relative weight of the total water storage capacity of a river or open channel due to the influence of upstream inflow and downstream outflow, and is dimensionless. This represents the storage coefficient, and its dimension is time (seconds). , , This is the Musking coefficient.
6. The method for constructing a water network system model according to any one of claims 4-5, characterized in that, The control object template includes at least one of the following templates: Control gate object template: Encapsulates the algebraic equations describing the current-carrying capacity of the control gate, with its core internal constraint formulas as follows: , in, This is the flow rate through the gate, measured in cubic meters per second. It is the flow rate coefficient, and the unit is the number of cubic meters flowing through the control gate per hour; This refers to the gate width, in meters. It is the acceleration due to gravity, measured in meters per second squared. and These are the water levels before and after the sluice gate, respectively, in meters; and This refers to the gate opening, measured in meters. Water diversion gate object template: The internal constraints of the water diversion gate are a set of... A system of equations consisting of equations, where the number of equations is 1. Let be the total number of downstream branches, and be a positive integer. Each downstream branch has a gate, and each equation describes the flow rate through the gate at the corresponding branch outlet: , , , in: Is flowing to the first The instantaneous flow rate of each downstream branch, in cubic meters per second. Integer and ; It is the first The gate is the first one. The opening degree of the gates on each downstream branch, in meters; This is the common upstream water level for all sluice gates, expressed in meters. It is the first The water level in the downstream branch canal / pipe, function It is an overcurrent formula; Pump station object template: Encapsulates the characteristic curve equations describing the performance of the pump station; its core internal constraint is the head-flow rate relationship. , The head-flow rate relationship is expressed as a function of the flow rate through the pumping station. The quadratic polynomial: , Among them, the pump station head The value is determined by the difference in water levels between the upstream and downstream sections it connects to, and the unit is meters. It is the instantaneous flow rate through the pumping station, measured in cubic meters per second, while the coefficient... , , Based on the water pump speed The decision is made regarding the water pump speed. The unit is revolutions per minute; Pipeline Valve Object Template: The core internal constraints of pipeline valves describe the instantaneous flow rate through the pipeline valve. Pressure difference between the two ends of the pipeline valve With pipeline valve opening Algebraic equation relating them: , in: It is the instantaneous flow rate through the pipeline valve, measured in cubic meters per second; It is the pressure difference between the upstream and downstream of a pipeline valve, measured in Pascals, and determined by the state of the upstream and downstream pipeline objects it is connected to. It is the flow coefficient of the pipeline valve, which is dimensionless; It is a unit conversion constant; Specific gravity of a fluid is dimensionless. Hydropower Unit Object Template: The core internal constraint of a hydropower unit is the equation: , in, It is the instantaneous power generation of the hydroelectric generator unit, measured in watts; It is the density of water, measured in kilograms per cubic meter. The flow rate through the hydroelectric generator unit is expressed in cubic meters per second. It is the net working head of the hydropower unit, measured in meters, and is determined by the water level difference between the upstream and downstream reservoirs or rivers to which it is connected. It is the overall efficiency of the unit, which is a non-linear function defined by a set of comprehensive characteristic curves or Hill diagrams.
7. The method for constructing a water network system model according to claim 3, characterized in that, Step S3 includes: on the graphical user interface, in response to the user's drag and connect operations, instantiating the corresponding software object from the standard object library, and constructing a directed graph representing the topology of the physical water network system based on the actual connection relationships of the physical water network. The directed graph includes: Node: Each node in the directed graph is a software object instance, which encapsulates all the physical parameters and internal constraint equations of the corresponding object; Directed edges: Directed edges connecting the nodes represent the hydraulic connections between the software object instances, specifying the upstream and downstream locations and the direction of water flow. The nodes and directed edges constitute the directed graph.
8. The method for constructing a water network system model according to claim 7, characterized in that, Step S4 includes: traversing the directed graph and performing the following steps: Extracting internal constraints: Extract the encapsulated internal constraint equations from each node of the directed graph; Generate coupling constraints: Based on the connection relationships between nodes in the directed graph, automatically generate coupling constraint equations describing the hydraulic connections between objects; Integrating to form a system model: combining all the extracted internal constraint equations and all the generated coupling constraint equations to form a set of mathematical model equations describing the dynamic behavior of the entire physical water network system.
9. A computer device, characterized in that, The method includes a memory, a first processor, and a first computer program stored in the memory and executable on the first processor. When the first computer program is executed by the first processor, it implements the water network system model construction method according to any one of claims 1-8.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium is used to store a second computer program, which can be executed by at least one second processor to cause the at least one second processor to perform the water network system model construction method according to any one of claims 1-8.
Citation Information
Patent Citations
Object-oriented hydrodynamic modeling element management method
CN107239657A
Large-watershed river system flood forecasting and dispatching integrated method, system, equipment and medium
CN114330825A
Digital twin water network construction method and computer equipment
CN117670579A
Water resource optimization regulation and control method for long-vine melon-bearing water network irrigation system
CN119443415A
Constructional engineering full-period collaborative management and risk prediction system
CN121304095A