Query optimization method based on improved genetic algorithm

A technology of query optimization and genetic algorithm, which is applied in the direction of genetic rules, calculations, genetic models, etc., can solve the problems of inaccurate search for local extremum, prolong search time, and reduce search accuracy, so as to improve query speed and shorten search Time, the effect of improving search accuracy

Active Publication Date: 2015-12-02
KUNMING UNIV OF SCI & TECH
View PDF2 Cites 11 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

As far as the genetic algorithm is concerned, it also has certain limitations, and it is easy to encounter the "premature" problem, that is, it only oscillates near the optimal solution in the later stage of the search, and falls into a local extremum and cannot accurately search for the global optimal solution. This not only prolongs the search time but also reduces the search accuracy.

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
  • Query optimization method based on improved genetic algorithm
  • Query optimization method based on improved genetic algorithm
  • Query optimization method based on improved genetic algorithm

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0027] Embodiment 1: as Figure 1-3 As shown, a query optimization method based on an improved genetic algorithm, the steps of the query optimization method are as follows:

[0028] Step1. Initial parameter setting: set the number of iterations G, the selection probability pc, the mutation probability pm, and define a query strategy set D as a search space. The query strategy in D requires n steps to complete the query task;

[0029] Step2. Establish a query strategy cost evaluation model: If the query strategy requires n steps to complete, then there are n+1 nodes in the query strategy space, the cost between two nodes is d, and the cost function is:

[0030] F ( X ) = Σ i = 1 n d x i x i ...

Embodiment 2

[0043] Embodiment 2: as Figure 1-3 As shown, a query optimization method based on an improved genetic algorithm, the steps of the query optimization method are as follows:

[0044] Step1. Initial parameter setting: set the number of iterations G, the selection probability pc, the mutation probability pm, and define a query strategy set D as a search space. The query strategy in D requires n steps to complete the query task;

[0045] Step2. Establish a query strategy cost evaluation model: If the query strategy requires n steps to complete, then there are n+1 nodes in the query strategy space, the cost between two nodes is d, and the cost function is:

[0046] F ( X ) = Σ i = 1 n d x i x i ...

Embodiment 3

[0056] Embodiment 3: as Figure 1-3 As shown, a query optimization method based on an improved genetic algorithm, the steps of the query optimization method are as follows:

[0057] Step1, initial parameter setting. A query strategy set D is defined as a search space, and the query strategies in D need 9 steps to complete the query task.

[0058] Step1.1. Determine initial parameters: number of iterations G=100, selection probability pc=0.2, mutation probability pm=0.4.

[0059] Step2. Establish a query strategy cost evaluation model. The time consumed by a certain query strategy to obtain the query result is the cost of this query strategy, and the function to calculate the cost of the query strategy is the cost function. A solution of the cost function provides a query strategy, and the query strategy set D is the solution space of the cost function.

[0060] Assuming that the query strategy requires n=9 steps to complete, then there are 10 nodes in the query strategy sp...

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 relates to a query optimization method based on an improved genetic algorithm, and belongs to the technical field of query optimization. The method comprises: establishing a mathematical model for a query execution policy set, to transform a query optimization problem into a mathematical problem of finding a global optimal solution, wherein the model is called a cost evaluation model of a query policy; and then improving a genetic algorithm, and using a global search ability of the improved genetic algorithm to perform a parallel search on a query policy set, thereby finally obtaining an ideal query execution policy. According to the method provided by the invention, a conventional genetic algorithm is improved, and the improved genetic algorithm is used for query optimization of a large relational database, thereby overcoming a "premature" convergence phenomenon. Compared with other intelligent optimization algorithms, falling into a local extremum can be effectively avoided, thereby shortening search time. In addition, a gene based search policy and a polyploidy based retention policy in the algorithm greatly improve search accuracy.

Description

technical field [0001] The invention relates to a query optimization method based on an improved genetic algorithm, belonging to the technical field of query optimization. Background technique [0002] Since the late 1960s, database technology has experienced more than 40 years of development and has become an important core technology of modern computer systems. Among them, the relational database is a mainstream database based on mathematical concepts, which can directly describe the actual relationship and has high access efficiency. But at the same time, relational databases also have corresponding defects. Their data structures are relatively complex, especially for large-scale relational databases. It is extremely complicated, and the query efficiency is low when performing multi-link query. However, it can be seen from the application examples of most database systems that the query operation occupies the largest proportion in various database operations, and the da...

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/30G06N3/12
CPCG06F16/2453G06N3/126
Inventor 邵剑飞任修仕
Owner KUNMING UNIV OF SCI & TECH
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products