Summary of the invention
Technical matters to be solved by this invention is the computer graphical technology of uses advanced, simplifies the accuracy of the complexity of electric weight formula configuration, the efficient that improves the configuration of electric weight formula, the configuration of guarantee electric weight formula.
Under the prerequisite that satisfies electric quantity data different aspects analyzing and processing demand, configuration management requirement of electric weight formula and operational approach are cured in the visual formula configuration template business accumulation of the configuration management of standard electric weight formula, continuity electric weight algorithm; In addition, for guaranteeing the accuracy of formula configuration, the formula verification is provided and has calculated two kinds of verification means immediately.Realize the high efficient and reliable formula configuration management tool of electric quantity acquisition application system, promoted electric quantity data analysis and management level.
For achieving the above object, the present invention takes following technical scheme to realize:
The visual configuration-system of electric weight formula is characterized in that: comprise
Visual configuration interface module: based on the Web application technology, adopt the Flash backstage technology of Flex(Adobe company) as the framework of visual configuration interface;
Visual formula configuration template and formula generating algorithm module: be used to dispose the electric weight formula, comprise
(1) common formula template: use stoichiometric point as initial conditions, its generating algorithm uses the stoichiometric point electric weight to generate the electric weight computing formula according to electric weight formula type;
(2) ratio formula template: other formula expression such as off line electric weight, component computing formula are as molecule and denominator on use stoichiometric point electric weight or the electric weight, and its generating algorithm generates ratio type computing formula and the legitimacy of denominator is carried out verification according to molecule and denominator;
(3) special formula template: freely select stoichiometric point electric weight or other formula as input component and customized expression content, support basic mathematical operational symbol, common mathematical function and logic determines expression formula, after the content of expression formula and grammer are carried out verification, save as the electric weight computing formula.
The visual configuration-system of aforesaid electric weight formula is characterized in that:
Also comprise electric weight formula verification module, described electric weight formula verification module comprises
The formula verification: formula option and expression formula content are carried out verification, check formula enabling time, computing time at interval, the validity of input component, the correctness of verification expression syntax;
Calculate immediately: the electric quantity data that uses the fixed time section provides formula result of calculation as the configuration reference as input quantity.
The exposition of electric quantity acquisition application system adopts the Web application technology of B/S framework, and the visual configuration management system of electric weight formula that the present invention realized also must be based on the application of Web.After having studied the various pattern technologies that can be used for Web, the present invention finally adopts the construction framework of Flex technology as visual configuration interface.
In the electric quantity acquisition application system, metering model is divided into area, factory station (power plant, transformer station), stoichiometric point three-decker; Electric quantity data comprise forward meritorious, oppositely meritorious, forward is idle, reverse idle four kinds of electric weight character.The electric weight formula configuration management that the present invention realized can system freely uses stoichiometric point electric weight (forward gain merit electric weight, oppositely meritorious electric weight, forward capacity of idle power, reverse capacity of idle power) as input quantity, the electric weight formula of definition factory station level and local level; In addition, for satisfying more complicated analyzing and processing demand, configuration-system can also use other formula result of calculation as the input component, realizes nested calculating.
For solving the existing problem that electric weight formula configuration management process is loaded down with trivial details and workload is huge, the present invention with electric weight formula commonly used abstract be visual formula configuration template, the input component (stoichiometric point electric weight or other formula) of selecting formula that pulls by mouse, graphical exhibition method with image, the intelligent algorithm that cooperates formula to generate, the final generation is used for the electric weight formula that coulometric analysis is calculated.The present invention provides three types formula configuration template and generating algorithm at present, comprising: common formula, ratio formula and special formula.Wherein said:
(1) common formula
Be used to dispose the electricity volume of power plant, off line electric weight.The configuration template of the type is directly selected stoichiometric point and the coefficient of stoichiometric point is set, and uses the input component of the electric weight character of stoichiometric point as the electric weight formula according to the formula generating algorithm of selecting automatically when the expression formula that generates.
(2) ratio formula
Be used to dispose the formula of ratio compute type such as line loss, network loss.The molecule and the denominator formula expression of ratio are set respectively, generate the electric weight formula of ratio type according to generating algorithm.
(3) special formula
Be used for self-defined electric weight formula, satisfy senior computation requirement.Can freely select stoichiometric point electric weight or other formula as input component and customized expression content, support basic mathematical operational symbol, common mathematical function and logic determines, the customized expression of process grammer and content verification can save as the electric weight formula.
The present invention has extensibility to the formula configuration-system, along with going deep into of service application, can customize formula configuration template and formula generating algorithm according to business demand.
Electric weight formula configuration template The Application of Technology, simultaneously also standard formula management.By using electric weight formula configuration templateization always, can limit the input component of formula configuration, avoid maloperation; Cooperate intelligent formula generating algorithm, can guarantee that the electric weight formula that generates calculates efficiently, configuration is accurate and meet management expectancy.
For guaranteeing the accuracy of formula configuration, the invention provides two kinds of verification means: formula verification and calculating immediately.Wherein, the formula verification is carried out verification to formula option and expression formula content, check formula enabling time, computing time at interval, the validity of input component, the correctness of verification expression syntax; The electric quantity data that calculates use fixed time section immediately provides formula result of calculation as the configuration reference as input quantity.
The beneficial effect that the present invention reached:
The invention solves the existing problem that electric weight formula configuration management process is loaded down with trivial details and workload is huge, use visual configuration management interface to simplify the complexity of electric weight formula configuration.Electric weight formula configuration template The Application of Technology, simultaneously also standard formula management.By using electric weight formula configuration templateization always, can limit the input component of formula configuration, avoid maloperation; Cooperate intelligent formula generating algorithm, can guarantee that the electric weight formula that generates calculates efficiently, configuration is accurate and meet management expectancy.
Embodiment
Below in conjunction with accompanying drawing the present invention is done concrete introduction:
Fig. 1 is a common formula configuration interface of the present invention, by the configurable electricity volume commonly used in this interface, off line electric weight computing formula.
Electricity volume formula, off line electric weight formula are electric quantity acquisition application system one of the computing formula of normal use, and its form is:
Certain power plant's electricity volume=(((certain .A of power plant switch forward meritorious+meritorious+0.9812 .C of the * power plant switch forward of certain .B of power plant switch forward is meritorious)-(certain .A of power plant switch oppositely meritorious+certain .B of power plant switch oppositely meritorious+0.9812 .C of * power plant switch is oppositely meritorious))+.A of abs((power plant switch forward is meritorious+and meritorious+0.9812 .C of the * power plant switch forward of certain .B of power plant switch forward is meritorious)-(certain .A of power plant switch oppositely meritorious+certain .B of power plant switch oppositely meritorious+0.9812 .C of * power plant switch is oppositely meritorious)))/2
Wherein, A, B, C switch refer to stoichiometric point, meritorious, the reverse meritorious electric weight character of stoichiometric point that is of forward.Abs is a system function, realizes absolute calculation.0.9812 be coefficient, decide on concrete power supply contract.The form and the electricity volume of off line electric weight are similar, and it is meritorious to subtract forward for oppositely gaining merit on concrete expression formula.
The present invention has customized visual formula configuration template for the electric weight computing formula of the type, as shown in Figure 1.After selecting electric weight formula type on the interface, selection participates in the stoichiometric point of electric weight calculating and is drawn in the component tabulation of lower right, interface from the metering model Tree control of left side, can show above-mentioned electric weight formula allocative effect figure in the visualized graphs zone.Define the coefficient of stoichiometric point if desired, can in the tabulation of stoichiometric point component, double-click the cell of coefficient row, can typing stoichiometric point coefficient.Under the default situations, newly-increased stoichiometric point coefficient is 1, does not show in graphic interface, if the user has edited the stoichiometric point coefficient, will highlight in the formula synoptic diagram that generates.The effect of visualization figure of electric weight formula configuration uses stoichiometric point and stoichiometric point coefficient as the input of model, uses the formula generating algorithm as processing module, the name of electric weight is referred to as output, has showed the deploy content of electricity volume, off line electric weight visually.
The generating algorithm of common electric weight formula uses above-mentioned stoichiometric point, stoichiometric point coefficient, electric weight formula type as initial conditions, generates corresponding electric weight through algorithm process and calculates formula expression.On configuration interface, select " formula is detailed " tab can view the concrete definition (as shown in Figure 2) of formula.
Use " formula checking " function can verify the correctness of formula definition, use " calculating immediately " function to obtain the result of calculation of a period of time, confirm with content to formula.After finishing aforesaid operations, to click " determining " button and just formula can be saved to database, the backstage computing engines can inquire this formula and it is calculated.
Ratio formula configuration template shown in Figure 3 comprises molecule and denominator tabulation, can accept stoichiometric point electric weight and other formula respectively as input, and its setting up procedure and common formula configuration template are similar.Its generating algorithm can generate ratio type electric weight computing formula according to the expression formula of molecule, denominator.Before preserving the formula configuration, need carry out verification to the configuration validity (non-0) of denominator.
The tabulation of the component of special formula configuration template shown in Figure 4 can be accepted stoichiometric point electric weight or other formula as input, generates component variable name (as a1, a2 etc.) automatically according to the order of input.Behind the component of determining formula definition, but the functions of use button is the typing formula expression in the expression formula input frame at interface, and mathematical operator (addition subtraction multiplication and division, bracket etc.), canonical function (abs, max, min etc.) and simple logic control (if, else etc.) supported in its grammer.Instrument carries out verification to expression formula before preserving formula definition, comprises expression formula content and grammer.In addition, can use the expression formula of computing function checking immediately correctness in definition.
Below announce the present invention as above with preferred embodiment, so it is not in order to restriction the present invention, and all technical schemes that mode obtained of taking to be equal to replacement or equivalent transformation all drop in protection scope of the present invention.