CN111652529B - Water engineering combined scheduling method - Google Patents

Water engineering combined scheduling method Download PDF

Info

Publication number
CN111652529B
CN111652529B CN202010629745.XA CN202010629745A CN111652529B CN 111652529 B CN111652529 B CN 111652529B CN 202010629745 A CN202010629745 A CN 202010629745A CN 111652529 B CN111652529 B CN 111652529B
Authority
CN
China
Prior art keywords
scheduling
condition
water
rule
water engineering
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010629745.XA
Other languages
Chinese (zh)
Other versions
CN111652529A (en
Inventor
陈�胜
杨永民
黄诗峰
龙爱华
刘舒
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China Institute of Water Resources and Hydropower Research
Original Assignee
China Institute of Water Resources and Hydropower Research
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China Institute of Water Resources and Hydropower Research filed Critical China Institute of Water Resources and Hydropower Research
Priority to CN202010629745.XA priority Critical patent/CN111652529B/en
Publication of CN111652529A publication Critical patent/CN111652529A/en
Application granted granted Critical
Publication of CN111652529B publication Critical patent/CN111652529B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/06Resources, workflows, human or project management; Enterprise or organisation planning; Enterprise or organisation modelling
    • G06Q10/063Operations research, analysis or management
    • G06Q10/0631Resource planning, allocation, distributing or scheduling for enterprises or organisations
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/448Execution paradigms, e.g. implementations of programming paradigms
    • G06F9/4488Object-oriented
    • G06F9/449Object-oriented method invocation or resolution
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45504Abstract machines for programme code execution, e.g. Java virtual machine [JVM], interpreters, emulators
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/04Forecasting or optimisation specially adapted for administrative or management purposes, e.g. linear programming or "cutting stock problem"
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q50/00Information and communication technology [ICT] specially adapted for implementation of business processes of specific business sectors, e.g. utilities or tourism
    • G06Q50/06Energy or water supply
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02ATECHNOLOGIES FOR ADAPTATION TO CLIMATE CHANGE
    • Y02A10/00TECHNOLOGIES FOR ADAPTATION TO CLIMATE CHANGE at coastal zones; at river basins
    • Y02A10/40Controlling or monitoring, e.g. of flood or hurricane; Forecasting, e.g. risk assessment or mapping

Landscapes

  • Engineering & Computer Science (AREA)
  • Business, Economics & Management (AREA)
  • Human Resources & Organizations (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • Economics (AREA)
  • General Physics & Mathematics (AREA)
  • Physics & Mathematics (AREA)
  • Strategic Management (AREA)
  • Tourism & Hospitality (AREA)
  • Marketing (AREA)
  • Entrepreneurship & Innovation (AREA)
  • General Business, Economics & Management (AREA)
  • Development Economics (AREA)
  • General Engineering & Computer Science (AREA)
  • Game Theory and Decision Science (AREA)
  • Operations Research (AREA)
  • Quality & Reliability (AREA)
  • Health & Medical Sciences (AREA)
  • Educational Administration (AREA)
  • Primary Health Care (AREA)
  • General Health & Medical Sciences (AREA)
  • Water Supply & Treatment (AREA)
  • Public Health (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)
  • Stored Programmes (AREA)

Abstract

The invention discloses a water engineering joint scheduling method, which comprises the following steps: analyzing the situation; step two: forecasting and calculating the water coming from the cross section; step three: performing water engineering combined dispatching calculation according to the water inflow condition of the section: calculating by using a water engineering combined dispatching system, and outputting a dispatching scheme by taking a specific incoming water forecast and a dispatching rule as input conditions; the water engineering joint scheduling system comprises a plurality of scheduling rules, wherein any scheduling rule comprises a scheduling condition and a scheduling operation, and the scheduling condition is expressed by adopting a conditional expression; before the calculation of the scheduling rules, dynamically compiling any plurality of scheduling rules into executable codes according to a specified calculation mode and a program interface, wherein the executable codes are a series of function pairs, and the function pairs consist of scheduling condition functions and scheduling operation functions; the object attribute values in the scheduling conditions and scheduling operations are directly replaced by the object index in the memory during compiling. The method can realize the dynamic management and the efficient calculation of the scheduling rule.

Description

Water engineering combined scheduling method
Technical Field
The invention relates to a water engineering combined scheduling method, belongs to the technical field of water engineering, and particularly relates to scheduling control over water engineering in a river basin under a specific flood condition so as to avoid or reduce loss caused by flood disasters to the maximum extent.
Background
The water engineering joint scheduling is to schedule water engineering under a specific flood condition so as to avoid or reduce the loss caused by flood disasters to the maximum extent. The realization of a corresponding informatization means, namely a water engineering combined dispatching system, and the optimization calculation result of the dispatching scheme have important significance for providing support information for flood control and disaster reduction dispatching decisions.
The management and implementation of the scheduling rules in the water engineering combined scheduling system are one of the difficulties in system implementation, in the traditional water engineering combined scheduling system, the scheduling rules are mostly implemented in a program hard coding mode, namely, the scheduling rule calculation is implemented through program logic, the scheduling rules in the hard coding mode are implemented to prevent flood and can not be increased, decreased or modified at any time in the later period, the scheduling effects in different water engineering application scenes can not be effectively researched, the actual application requirements of water engineering combined scheduling can not be effectively met, and the practicability of the scheduling application system is greatly reduced. For example, the reservoir can discharge 1000m when reaching flood limit water level3S is the default scheduling rule written in the program by hard coding, if the user wants to know about flood discharge 500m3The scheduling operation effect of/s requires adjusting the scheduling rule by modifying the program code, which is obviously not practical in practical application.
The expression, analysis and calculation of the scheduling rules are also difficult to implement in the scheduling system. In the existing similar application system, the condition of the scheduling rule is partially realized according to a logic tree (such as the scheduling rule management in the one-dimensional flood analysis software MIKE11 of DHI), the method indicates that the scheduling rule has the problems that a user is difficult to understand and the system is difficult to realize, meanwhile, the calculation efficiency is not high enough because the logic condition needs to be analyzed in each scheduling calculation, and when reservoir engineering joint optimization scheduling calculation needs to be carried out (thousands of scheduling rule calculations may need to be carried out), the calculation efficiency is difficult to meet the actual application requirements. In the aspect of expression of scheduling conditions, a function similar to field query of ArcMap software of the Esri company expresses a retrieval condition in a 'conditional expression' mode, and a 'condition' part of a scheduling rule is expressed in an expression mode.
In summary, the following problems exist in the prior art:
the traditional scheduling rule 'condition' expression based on the expression needs to be analyzed in each scheduling calculation, so that the calculation efficiency is low, and the water engineering joint optimization scheduling calculation cannot be supported; secondly, based on the dispatching rule expressed by the logic tree, when the dispatching rule is complex, the user can not understand the dispatching rule easily, and the system is difficult to realize; and thirdly, the traditional scheduling rule based on hard coding cannot dynamically increase, decrease and modify, cannot simulate a multi-scene scheduling scheme, and has low applicability and difficult popularization and application.
Disclosure of Invention
In order to overcome the problems in the prior art, the invention provides a water engineering joint scheduling method, which can realize the dynamic management of the scheduling rules, the expression mode of the 'condition' part of the scheduling rules is easy to understand and is easy to realize through an application system, the corresponding scheduling rules have high calculation efficiency, and the optimization calculation of the water engineering joint scheduling scheme can be supported.
Specifically, the invention comprises the following technical scheme:
a water engineering combined scheduling method comprises the following three steps:
the method comprises the following steps: and (3) formal analysis: collecting weather forecast and flood forecast data, judging whether water engineering joint scheduling is needed, and if so, sequentially executing the second step and the third step;
step two: forecasting and calculating the water coming from the section: calculating the water inflow condition of the section according to the rainfall condition and the upstream water inflow condition;
step three: performing water engineering combined dispatching calculation according to section water inflow forecast;
performing water engineering joint scheduling calculation analysis through a water engineering joint scheduling system, wherein the water engineering joint scheduling system takes specific water incoming conditions and scheduling rules as input conditions and outputs a scheduling scheme; the water engineering joint scheduling system comprises a plurality of scheduling rules, wherein any scheduling rule comprises a scheduling condition and a scheduling operation, and the scheduling condition is expressed by adopting a conditional expression; before the calculation of the scheduling rules, dynamically compiling any plurality of scheduling rules into executable codes according to a specified calculation mode and a program interface, wherein the executable codes are a series of function pairs, and the function pairs consist of scheduling condition functions and scheduling operation functions; the object attribute values in the scheduling conditions and scheduling operations are directly replaced by the object index in the memory during compiling.
Furthermore, the water engineering joint scheduling system loads all scheduling rule programs through a reflection mechanism when the scheduling rules are loaded.
Further, the calculation process of the scheduling rule includes: 1) loading the program set through a reflection mechanism; 2) acquiring a scheduling rule list; 3) and executing the function pair of the scheduling rule, calling a scheduling condition function, and calling a scheduling operation function by the system when the condition function meets the condition to realize corresponding water engineering scheduling calculation.
Further, if the scheduling condition is empty in step 3), the scheduling operation function is directly executed.
Further, the arbitrary plurality of scheduling rules refers to two or more scheduling rules.
The invention has the advantages and beneficial effects that:
the invention dynamically compiles the scheduling rules into a callable code program according to the specified interface through a dynamic compiling technology, defines a general scheduling rule calculation mode (a 'condition-operation' scheduling calculation mode) through the interface, supports the arbitrary increase, decrease and modification of the scheduling rules, and supports the dynamic management of the scheduling rules.
The method realizes the high-efficiency calculation of the scheduling rule (including the expression of the scheduling 'condition') through the dynamic compiling technology, and directly replaces the object attribute values in the 'scheduling condition' and the 'scheduling operation' with the object index in the memory during compiling.
The invention is based on the realization of the expression 'condition' expression of the scheduling, the 'condition' part of the scheduling rule of the water engineering scheduling is expressed in the form of the conditional expression, the conditional expression is compiled into the executable code in the form of dynamic compilation, the conditional expression does not need to be analyzed during scheduling calculation, the calculation efficiency is high, the user can easily understand the expression mode of the scheduling 'condition' realized by the method, and the system is also easy to realize.
In conclusion, the method improves the availability of the water engineering combined dispatching system, greatly improves the efficiency of dispatching rule calculation, provides technical support for water engineering combined dispatching optimization calculation, and lays a foundation for popularization and application of the water engineering combined dispatching application system.
Drawings
The invention is further illustrated by the following figures and examples.
FIG. 1 is an overall flow chart of the present invention for implementing dynamic management and efficient computation of scheduling rules by using a water engineering joint scheduling system.
FIG. 2 is a schematic diagram of the present invention, a scheduling rule management in the form of a logical tree.
FIG. 3 is a schematic diagram of the present invention, a scheduling rule expression form.
FIG. 4 is a structural design of the scheduling rules program of the present invention.
FIG. 5 is a diagram of a scheduling rule dynamic compilation of a relationship between a set of programs and related objects.
FIG. 6 is a flow chart of implementing dynamic compiling of scheduling rules according to the present invention.
Detailed Description
The first embodiment is as follows:
a water engineering combined scheduling method comprises the following three steps:
the method comprises the following steps: and (3) formal analysis: collecting weather forecast and flood forecast data, judging whether water engineering joint scheduling is needed, and if so, sequentially executing the second step and the third step;
step two: forecasting and calculating the water coming from the section: calculating the water inflow condition of the section according to the rainfall condition and the upstream water inflow condition;
step three: performing water engineering combined dispatching calculation according to section water inflow forecast: performing water engineering joint scheduling calculation analysis through a water engineering joint scheduling system, wherein the water engineering joint scheduling system takes specific water incoming conditions and scheduling rules as input conditions and outputs a scheduling scheme; the water engineering combined dispatching system comprises a plurality of dispatching rules, wherein any dispatching rule is divided into a dispatching condition and a dispatching operation, and the dispatching condition is expressed by adopting a condition expression; before the calculation of the scheduling rules, dynamically compiling any plurality of scheduling rules into executable codes according to a specified calculation mode and a program interface, wherein the executable codes are a series of function pairs, and the function pairs consist of scheduling condition functions and scheduling operation functions; the object attribute values in the scheduling conditions and scheduling operations are directly replaced by the object index in the memory during compiling.
And in the third step, a water engineering joint scheduling system is adopted to carry out water engineering joint scheduling calculation analysis, and in order to realize dynamic management and efficient calculation of scheduling rules, the improvement of the scheduling rules part comprises three main steps, namely dynamic expression and management of the scheduling rules, dynamic compilation of the scheduling rules and calculation of the dynamic scheduling rules. The overall flow chart of the embodiment is shown in fig. 1.
1. Expression and management of scheduling rules: the invention defines any scheduling rule in the water project joint scheduling system as a 'condition-operation' part, when the 'condition' is satisfied, the system executes corresponding 'operation', and when the 'condition' is not satisfied, the 'operation' is not executed, corresponding to the scheduling rule of the actual water project joint scheduling service. If' the water level of a certain reservoir reaches the flood limit water level, the flood discharge gate is opened to discharge the flood for 200m3And/s 'under the condition that the water level of a certain reservoir reaches the flood limit water level, and correspondingly, the corresponding operation is' opening the flood discharge gate to discharge 200m3And/s', acquiring the attribute of the corresponding object in the scheduling application system to judge (namely, judging the condition), and setting the state value of the project (namely, scheduling the operation). In actual business, it is possible that the scheduling conditions may be complicated, such as "when the upstream reservoir is lower than the flood-control high water level and the downstream water level is higher than the warning water level, or when the upstream reservoir is higher than the warning water level, the reservoir keeps the discharge amount of 300m3S ", scheduling the" bar "at this timeA piece "is a logical combination of several basic" conditions ". There is also an unconditional scheduling rule, for example, "reservoir level is kept below 150 m", and "condition" is null, indicating that "condition" determination is always true. The scheduling rule can be expressed as two parts of "condition-operation" in a canonical form, where the form of "operation" is relatively fixed and is a modification to the state of the scheduling object, and the "condition" part is relatively complex and may be a combination of multiple basic "conditions".
In this embodiment, a normalized form expression of a scheduling rule is defined, one water engineering joint scheduling calculation scheme includes any multiple scheduling rules, and one scheduling rule can be divided into two parts, namely, a conditional expression and scheduling control (i.e., scheduling operation, the same applies below), in the following form:
R={Ce,{O,AoOP, V } } equation 1
Wherein R represents a scheduling rule, CeIs the scheduling condition, { O, AoOP, V represents dispatch control, O represents an object to be controlled, such as a certain reservoir; a. theoAn attribute (or state) of the controlled object, such as a current water level of the reservoir; OP represents an operation symbol, e.g. to control the discharge of a reservoir to below a certain value (the mathematical symbol is) "<"); v denotes a specific operating value, e.g. control leakage not higher than 1000m3And/s, then 1000 is the operating value. CeThe scheduling condition may be relatively complex, so the present invention is expressed in the form of an expression, and an example of the scheduling condition expression is as follows:
([ # horizontal head |50700401#) ] [ water level ] >56 or [ # six safety hydrological station |958311QX #) ] [ water level ] >67)
And ([ # buddhist ridge reservoir |50701000#) ] [ water level ] <120)
Wherein "[ # horizontal head |50700401#) ] represents the horizontal head section object, and the coding after the" | "symbol is used for ensuring the uniqueness of the water engineering object (preventing the water engineering object name from being possibly repeated); "[ water level ]" indicates the "water level" attribute of the horizontal row head. The meaning of the conditional expression of the entire scheduling rule is that the "when the water level of the horizontal row head is higher than 76m or the water level of the six ampere hydrological stations is higher than 67m, and the water level of the budding ridge reservoir is lower than 120 m" condition "is satisfied to perform the corresponding operation. In the mode, the conditional expressions can be combined arbitrarily through brackets and logic expressions to realize the expression of various complex scheduling conditions. The conditional expressions can be managed by the implementation of the application software of the application system to facilitate the user's scheduling rules (see fig. 2), and the objects and attributes can be entered by selection. Compared with a management mode based on a logical tree (such as fig. 3), which needs to manage scheduling conditions through a logical hierarchical relationship, a condition and condition combination relationship, a combination relationship of condition and condition grouping, and the like, the interface is complex, and users are difficult to understand, the management mode of the scheduling rule is easier for users to understand and the application system is easier to implement.
2. Dynamic compilation of scheduling rules: the dynamic compiling of the scheduling rule is divided into two functions, wherein one function is to dynamically compile the conditional expression to mainly solve the problem of computational efficiency, and the other function is to dynamically compile according to a certain interface to form a computing mode of the scheduling rule, so that the dynamic management of the scheduling rule is supported.
The method compiles the conditional expression into an executable code in a dynamic compiling mode before the calculation of the scheduling rule, and compiles the related objects in the scheduling 'condition' into the memory index of the object, so that the conditional expression does not need to be analyzed and the value of the object does not need to be searched when in scheduling calculation, and the calculation efficiency is high. In this mode, the conditional expression can be simply converted into a program statement (the logic expression is basically the same as the program statement) during compiling, the application of complex scheduling 'conditions' is supported, the calculation efficiency is high (the expression is analyzed without calculation), and the requirements of functions and performance of the water engineering combined scheduling application system are met.
The method dynamically compiles the scheduling rules into executable codes according to a certain program interface form to form a calculation mode of the scheduling rules, thereby supporting the dynamic management and the efficient calculation of the scheduling rules. The program interface means that a type of objects of the system have the same function or attribute according to a certain specification, and can be recognized and called by the system according to a certain mode (if the objects are loaded and called through a reflection mechanism). Because the scheduling rule can be divided into two parts of a conditional expression and scheduling control (namely scheduling operation), the scheduling rule can be defined into a series of objects (the invention is a 'function pair', namely two functions in pair correspond to a 'condition' part and an 'operation' part respectively) according to a certain interface, and thus, the loading and execution of any plurality of similar objects are supported, the loading and execution of any plurality of scheduling rules are supported, and the calculation mode supporting the increment, the decrement and the modification of the scheduling rule is formed without modifying codes. The dynamically compiled scheduling rules form executable code (assemblies) and structures of the following patterns within the application system.
{Gf,OPf,{RkH, where k is 1,2 … … n, equation 2
In the above formula, GfAnd OPfTwo methods for software device presetting in this embodiment, GfIn order to obtain a uniform function method of object attribute values, a water engineering object and attribute (which are fixed format objects and attribute indexes in a memory) are obtained by the method during calculation of each scheduling rule; OP (optical fiber)fA unified function method for scheduling operation calls a related scheduling operation service method of the water engineering joint scheduling system (an application system can define different scheduling operation service methods according to different water engineering objects and does not belong to the coverage range of the invention); { RkThe scheduling rules are formed after dynamic compilation, and each scheduling rule corresponds to one Rk. Each RkComprising a pair of functions, each being a scheduling condition function (Fcondition)k) And scheduling operation function (Fcontrol)k) As shown in the following formula.
Rk={Fcontrolk,FconditionkEquation 3
Scheduling Condition function (Fcondition)k) Is generated after the conditional expression is analyzed (wherein the object and the attribute are replaced by G)fMethod), scheduling operation function (Fcontrol)k) The code of (2) has scheduling operation related information analysis generation (mainly by calling OP)fA method to implement).
To better illustrate the computing modes and software settings to implement dynamic schedulingA rule program is an example. The 'function pairs' of a series of compiled scheduling rules are packaged in a class named RuleExcutor Runtime (see FIG. 4), and each scheduling rule generates a 'function pair' (R)k) Fcontrol thus generatedkMethod and FconditionkThe method also has a number, and functions in the actual code, such as control function1() and RuleFunction1(), are used for realizing the related functions of the scheduling rules and calling the efficient calling of the objects (i.e. the communication of the scheduling rules part with other parts of programs, such as obtaining the scheduling objects and the attribute values). The invention defines an IRuleProcessor interface which needs to realize GfAnd OPfThe two methods are used for obtaining attribute values of the scheduling related water engineering objects and controlling the scheduling related water engineering objects respectively, when the RuleExcutor Runtime object is called, the object for realizing IRuleProcessor is transmitted, and the RuleExcutor Runtime object can pass through the IRuleProcessor (G) two methodsfAnd OPf) And acquiring the attribute value of the object in the memory and controlling the related scheduling object, thereby realizing the communication between the scheduling rule program and the main scheduling program.
The dynamic compiling of the scheduling rule requires a program language to support the dynamic compiling function, but most high-level languages support the dynamic compiling technology, such as C #, Java, and the like, and the embodiment is implemented by using C # speech. Through the management and compiling mechanism of the scheduling rules, any number of scheduling rules can be added in an application system, so that the dynamic management of the scheduling rules is realized; the compiled code does not need to analyze the scheduling condition in the scheduling calculation, and the calculation efficiency is also very high.
3. And (3) calculating a scheduling rule: as described above, the scheduling rules have been compiled into executable code (RuleExcutorRuntime object) prior to the computation of the water engineering joint scheduling scheme. In the example of fig. 4, the implementation object of the IRuleProcessor interface includes two methods, namely GetConditionVal and ControlAction, and the method GetConditionVal (i.e. G)f) The parameter objid represents the number of the object in the memory, the parameter attembutid represents the attribute number of the object, and the specified attribute value of the specified water engineering object can be obtained; method ControlAction (i.e., OP)f) Represents the object to be controlled by the parameter ojbidThe number, attenbuteid represents the attribute number of the object to be controlled, optype represents the control operation type (such as "greater than", "less than", etc.), valpara represents the value of specific control, and the scheduling control of the water engineering object can be realized. Scheduling condition function RuleFunction (i.e., Fcondition)k) The GetConditionationVal (i.e., G) will be called from an object implemented by the incoming IRuleProcessorf) Acquiring the value of a required object in the conditional expression; scheduling operation function ControlFunction (i.e., Fcontrol)k) An object realized according to the incoming IRuleProcessor calls a controlAction (namely OP)f) And carrying out scheduling control. The communication between a caller and a called object is realized through a mutual calling mechanism, so that the object value is quickly acquired from the memory and the related control is performed by the function pair of the scheduling rule. The relationship between the dynamically compiled set of scheduling rules and the caller is shown in FIG. 5.
When the water engineering scheduling scheme is calculated, the calculation of the scheduling rule is embedded in each calculation step, namely the calculation of the scheduling rule is called in each calculation process. The calculation process of the scheduling rule mainly comprises the following steps: loading a program set, and constructing an object of any class in the running state of the program through a reflection mechanism (the reflection mechanism refers to that the object of any class can be constructed, the class to which any object belongs can be known, member variables and methods of any class can be known, and the attribute and the method of any object can be called; C #, Java and other high-level languages have reflection mechanisms); acquiring a scheduling rule list; and executing 'function pair' of the scheduling rule. The whole execution flow of the scheduling rule is shown in fig. 6. It should be noted that, when the "function pair" of the scheduling rule is executed, two types of scheduling rules are distinguished, one type is a conditional scheduling rule, and the other type is an unconditional scheduling rule. The conditional scheduling rule is a scheduling rule having a conditional expression, and when the condition is judged to be established, the scheduling control method is executed. The unconditional scheduling rule is a scheduling rule without scheduling conditions, and the scheduling control method is directly executed at this time (for example, the unconditional scheduling rule is used when the reservoir level must be controlled to be below the check flood level in any case). When the dispatching rule is calculated for multiple times and the water engineering joint dispatching optimization calculation needs millions of times, firstly, and secondly, the dispatching rule list is stored in a memory only by being executed once during the first calculation, and the function pair of the list is directly called for calculation at other times.
The dynamic configuration and the efficient calculation of the scheduling rules of the water engineering joint scheduling method are supported through the realization of an expression representation method of the scheduling conditions, the dynamic compiling of the scheduling rules and a scheduling rule calculation method. Through the practical use of an application system, 10000 times of calculation of all the scheduling rules of the water engineering combined scheduling scheme of the Anhui province and river basin need 3 seconds, and the calculation result is verified to be in accordance with the setting of the scheduling rules. Therefore, the implementation method based on the dynamic water project joint scheduling rule can realize dynamic management of the scheduling rule, can realize efficient calculation of the scheduling rule, lays a foundation for optimized calculation of a water project joint scheduling scheme, and has good application and popularization values.
The above embodiments are only part of the present invention, and do not cover the whole of the present invention, and on the basis of the above embodiments and the attached drawings, those skilled in the art can obtain more embodiments without creative efforts, and therefore, the embodiments obtained without creative efforts should be included in the protection scope of the present invention.

Claims (4)

1. A water engineering combined scheduling method comprises the following three steps:
the method comprises the following steps: and (3) formal analysis: collecting weather forecast and flood forecast data, judging whether water engineering joint scheduling is needed, and if so, sequentially executing the second step and the third step;
step two: forecasting and calculating the water coming from the section: calculating the water inflow forecast of the section according to the rainfall condition and the upstream water inflow condition;
step three: performing water engineering combined dispatching calculation according to section water inflow forecast;
the method is characterized in that: performing water engineering joint scheduling calculation analysis through a water engineering joint scheduling system, wherein the water engineering joint scheduling system takes specific incoming water forecasting and scheduling rules as input conditions and outputs a scheduling scheme; the water engineering joint scheduling system comprises a plurality of scheduling rules, wherein any scheduling rule comprises a scheduling condition and a scheduling operation, and the scheduling condition is expressed by adopting a conditional expression; the normalized form of the scheduling rule is as follows:
R={Ce,{O,AoOP, V } } equation 1
Wherein R represents a scheduling rule, CeIs the scheduling condition, { O, AoOP, V represents dispatch control, O represents a controlled object, which includes a certain reservoir; a. theoThe attribute of the controlled object comprises the current water level of the reservoir; OP represents an operation symbol comprising the mathematical symbol "<"; v represents a specific operating value, including a control leakage; before the calculation of the scheduling rules, dynamically compiling any plurality of scheduling rules into executable codes according to a specified calculation mode and a program interface, wherein the executable codes are a series of function pairs, and the function pairs consist of scheduling condition functions and scheduling operation functions; directly replacing the object attribute values in the scheduling condition and the scheduling operation with object indexes in the memory during compiling; the program interface refers to that one class of objects of the system have the same function or attribute according to a certain specification and can be identified and called by the system according to a certain mode; the dynamically compiled scheduling rules form executable code in the application system in the following modes:
{Gf,OPf,{Rkequation 2
In the formula, GfAnd OPfTwo methods of software device initialization, GfIn order to obtain a uniform function method of object attribute values, a water engineering object and attributes are obtained through the method when each scheduling rule is calculated; OP (optical fiber)fCalling a related dispatching operation business method of the water engineering joint dispatching system for dispatching and operating a unified function method; { RkThe scheduling rules are formed after dynamic compilation, and each scheduling rule corresponds to one RkEach RkThe method comprises a pair of functions, namely a scheduling condition function and a scheduling operation function, which are shown as the following formula:
Rk={Fcontrolk,Fconditionkequation 3
In the formula: fconditionkFor scheduling conditional functions, the codes are generated after being analyzed by conditional expressions, wherein objects and attributes are replaced by GfA method; fcontrolkFor the function of scheduling operation, the code is generated by analyzing the information related to the scheduling operation, and the OP is calledfThe method is realized;
the 'function pair' of a series of compiled scheduling rules is encapsulated in a class named RuleExcutor Runtime, each scheduling rule generates a 'function pair', and the generated FcontrolkMethod and FconditionkThe method also has a number; defining IRuleProcessor interface, which needs to implement GfAnd OPfThe two methods are respectively used for obtaining attribute values of scheduling related water engineering objects and controlling the scheduling related water engineering objects, then calling RuleExcutor Runtime objects to transmit objects for realizing IRuleProcessor, and the RuleExcutor Runtime objects obtain the attribute values of the objects in the memory and control the related scheduling objects through the IRuleProcessor, so as to realize the communication between the scheduling rule program and the main scheduling program;
the calculation process of the scheduling rule comprises the following steps: 1) loading the program set through a reflection mechanism; 2) acquiring a scheduling rule list; 3) and executing the function pair of the scheduling rule, calling a scheduling condition function, and calling a scheduling operation function by the system when the condition function meets the condition to realize corresponding water engineering scheduling calculation.
2. The water engineering joint scheduling method according to claim 1, wherein: and the water engineering combined dispatching system loads all dispatching rule programs through a reflection mechanism when the dispatching rules are loaded.
3. The water engineering joint scheduling method according to claim 1, wherein: and in the step 3), if the scheduling condition is empty, directly executing the scheduling operation function.
4. The water engineering joint scheduling method according to claim 1, wherein: the arbitrary plurality of scheduling rules refers to two or more scheduling rules.
CN202010629745.XA 2020-07-03 2020-07-03 Water engineering combined scheduling method Active CN111652529B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010629745.XA CN111652529B (en) 2020-07-03 2020-07-03 Water engineering combined scheduling method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010629745.XA CN111652529B (en) 2020-07-03 2020-07-03 Water engineering combined scheduling method

Publications (2)

Publication Number Publication Date
CN111652529A CN111652529A (en) 2020-09-11
CN111652529B true CN111652529B (en) 2021-03-23

Family

ID=72345166

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010629745.XA Active CN111652529B (en) 2020-07-03 2020-07-03 Water engineering combined scheduling method

Country Status (1)

Country Link
CN (1) CN111652529B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113408875A (en) * 2021-06-03 2021-09-17 长江勘测规划设计研究有限责任公司 Method for constructing reservoir dispatching rule base with expansibility and structurization
CN117057335B (en) * 2023-10-12 2024-01-05 中国水利水电科学研究院 Intelligent generation method for four pre-schemes of flood control in drainage basin

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102296562A (en) * 2010-06-25 2011-12-28 华东电网有限公司 Step reservoir joint flood scheduling optimization method coupling flood protection with power generation
CN102419580A (en) * 2011-10-13 2012-04-18 贵州东方世纪科技有限责任公司 Flood forecasting and dispatching system
CN107609787A (en) * 2017-09-27 2018-01-19 福建四创软件有限公司 Automatic scheduling method is combined based on the lock pump group for automatically generating prediction scheme

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111225034B (en) * 2019-12-19 2021-09-28 中国科学院南京地理与湖泊研究所 WebService-based dynamic integration method and assembly of water environment safety regulation and control model

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102296562A (en) * 2010-06-25 2011-12-28 华东电网有限公司 Step reservoir joint flood scheduling optimization method coupling flood protection with power generation
CN102419580A (en) * 2011-10-13 2012-04-18 贵州东方世纪科技有限责任公司 Flood forecasting and dispatching system
CN107609787A (en) * 2017-09-27 2018-01-19 福建四创软件有限公司 Automatic scheduling method is combined based on the lock pump group for automatically generating prediction scheme

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
水工程联合调度平台研发及实务;WITWFYS;《豆丁文库》;20200226;第1-52页 *

Also Published As

Publication number Publication date
CN111652529A (en) 2020-09-11

Similar Documents

Publication Publication Date Title
Ghamarian et al. Modelling and analysis using GROOVE
CN102542382B (en) The method of operating of business rule and device
US9916136B2 (en) Interface infrastructure for a continuation based runtime
CN111652529B (en) Water engineering combined scheduling method
US8448132B2 (en) Systems and methods for modifying code generation templates
CN100405294C (en) System, method and program product to optimize code during run time
CN102521120A (en) Software automation test system and method
CN101221637B (en) Method for runtime execution of one or more tasks defined in a workflow process language
CN111309292B (en) MATLAB/Simulink-based full-model executable program construction method
CN110175027A (en) A kind of method and apparatus for developing business function
Oliveira et al. Advanced stochastic petri net modeling with the mercury scripting language
CN103443761A (en) Unchanged object mamagement
CN112148278A (en) Visual block chain intelligent contract framework and intelligent contract development and deployment method
CN102708452A (en) Water quality analyzing/calculating service system supporting dynamic compiling
CN115639980A (en) Draggable front-end logic arrangement method and device for low-code platform
CN115640045A (en) Low-code development platform based on domain-driven design and business system creation method
CN101853174A (en) Method and device for synchronizing defining and calling of string resource
Mannadiar et al. Domain-specific engineering of domain-specific languages
CN102214103A (en) Method and system for establishing and performing task program based on functional unit
CN109753281B (en) Micro-grid energy management strategy visualization development tool based on graphical programming
CN102387264B (en) The processing method of call control strategy, device and call center
CN112347534B (en) Water conservancy and hydropower engineering BIM model conversion method based on IFC extension
CN105975381B (en) Malfunction monitoring expert system integrating and developing platform
Jrad et al. Description and evaluation of elasticity strategies for business processes in the cloud
CN102541564B (en) A kind of UI multiplexing method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant