Unlock instant, AI-driven research and patent intelligence for your innovation.

Rapid computational formula loop point detecting method

A technology of calculation formulas and detection methods, applied in the computer field, can solve the problems of loops, entering an infinite loop or stack overflow, etc., to achieve the effect of improving the running speed and the correctness of the calculation.

Inactive Publication Date: 2013-12-25
STATE GRID CORP OF CHINA +2
View PDF2 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

The variable may be the calculation result of other formulas, but when defining other calculation formulas, it is necessary to make sure that the current calculation formula is not referenced, otherwise it will cause a loop, and errors such as an infinite loop or stack overflow will occur during calculation.

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Rapid computational formula loop point detecting method
  • Rapid computational formula loop point detecting method
  • Rapid computational formula loop point detecting method

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0017] The present invention will be described in detail below in conjunction with the accompanying drawings.

[0018] The analysis process of the present invention is as image 3 shown.

[0019] 1. Read the list of all calculation formulas.

[0020] 2. If the list is not empty, analyze it recursively. There are two conditions for interruption, one is that all formulas have been detected, and the other is that there are abnormal loop points in the formulas.

[0021] 3. The left side of the equal sign of all calculation formulas is marked as the left operand, and the right side is marked as the right operand. The right operand can also be a calculation formula.

[0022] 4. First put all the left operands into a list, and when recursively looping to a calculation formula, judge whether all the right operands are in the left operand list in turn, and if so, extract the formula represented by the left operand to the new calculation formula list for the next recursive use. If ...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention discloses a rapid computational formula loop point detecting method, which specifically comprises the steps of (1) reading lists of all computational formulas; (2) carrying out recursive analysis when the list are judged not to be void; (3) identifying the left sides of equal marks of all the computational formulas as left operands, and identifying the right sides of equal marks of all the computational formulas as right operands; (4) placing all left operands into a list; when a recursion circulates to a computational formula, whether all right operands of the computational formula are located in a left operand list or not is judged in sequence, if so, the computational formula represented by the left operands is extracted into a new computational formulas list, and is used in case of next recursion; if not, no processing is carried out, a next computational formula is continued; (5) when the recursion ends the circulation, a loop point is determined. By using the method, the problem that a computer enters an endless loop or resources of the computer are exhausted when the computer carries out data computation can be effectively solved, the operation speed of the computer can be improved, the method can be implanted into a relevant application system by simple configuration, and the computation correctness can be improved.

Description

technical field [0001] The invention belongs to the field of computers, and relates to problems involved in fields such as one-way linked lists, two-way linked lists and mathematical formula calculations in computer data structures, and specifically relates to a fast detection method for loop points of complex calculation formulas. Background technique [0002] In actual business systems, it is often encountered that data results need to be calculated. In calculation formulas, not all calculations are constants, but some are variables. The variable may be the calculation result of other formulas, but when defining other calculation formulas, it is necessary to make sure that the current calculation formula is not referenced, otherwise it will cause a loop, and errors such as an infinite loop or stack overflow will occur during calculation. In order to avoid this situation, it is necessary to find the loop point before calculation, such as figure 1 The thick line part. Co...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
Patent Type & Authority Applications(China)
IPC IPC(8): G06F17/30G06F9/44
Inventor 苏丹吴佳吴舜李坤高崧聂正璞许大卫杜剑雯刘昀来骥王黎李贤李晓东李超刘志伟杨帆李雪梅那琼澜
Owner STATE GRID CORP OF CHINA