Application of Genetic Algorithm in Test Project

xiaoxiao2021-03-05  35

Genetic algorithm in the test group volume, I use the genetic algorithm under Windows under the C #, I don't know which master can help me solve the urgent urgent? My current level is really no way to write this genetic algorithm, ask for help! Below is an introduction to the genetic algorithm.

Genetic Algorithm Description Genetic Algorithm is a parallel, effective optimized algorithm, based on Morgan's gene theory and Eldridge and Gould interrupt intermittent balance theory, while combining Mayr's edge species formation theory and some ideas of BertalanffV general system theory, Simulated Darwin's nature genetics: inheritance (genetic genetics), evolutionary (gene mutation) wins in the fittest (excellent gene is genetically replicated, inferior genes are genetically replicated). It is a search algorithm that combines the natural selection of the advantageous fittings of the natural world, the evolutionary mechanism of the survival of the fittest and the random information exchange mechanism between individuals and individuals in the same group. Using Genetic Algorithm Solving Problem First, you need to represent the required solutions into binary coding, then conduct basic operations according to the environment: Selection, Crossover, Mutation ... This continuous so-called "survival selection", and finally converge to a most adaptive environment On the individual's individual, the best solution is obtained. [6,7] 4 Genetic Algorithm Application In general, users will propose multifaceted requirements for the quality of the test paper when the automatic group volume, such as the sum of the topic, the average difficulty, the proportion, the proportion of chapters, the proportion of key chapters, knowledge Card and synthesis, etc., the automatic group volume should maximize the requirements of the user. Therefore, before the group volume, we first establish a control indicator for the automatic group volume, each line of each line of D = [] D consists of a test indicator of a test, such as the title number, the subject, chapter, difficulty, etc. And these attribute indicators are encoded to represent binary forms, and each column is all of the values ​​of a certain indicator in the question bank. In a specific problem, the examination may not use all indicators, so the individual D_Target contained in D_Request and D_VOID, D_Request indicate the control indicator required by the examination, D_VOID indicates the control indicator of the examination. That is, D_Target :: = : :: = {0, 1} m :: = {0, 1} n Test Question Bank [STK] All entered the corresponding attribute indicator. The form of test model is: if then :: = {0, 1, #} m # represents any one between 0 and 1. The genetic algorithm for the test automatically issues is as follows: (1) According to the test requirements of the examination, the data in the status space library D is planned, reserved the D_Request section, not the D_VOID portion, encoding the remaining parts D [1], D [2], ... d [i]. (2) Initialization Test Questioner [STK]. Randomly draw a set of questions from the question bank, and perform numbered STK [1], STK [2] ... STK [J], determine the appropriate exchange probability PC and variation probability PM; and define its adaptable value Flexibility [K] (K] = 1, 2 ... j) flexibility [k] <- 0 (k = 1, 2 ... j) (3) Remove STK [M] (0 ≤ M ≤ J) from the test case [STK] and state space Indicator D [N] (0 ≤ ≤ I) in library [D] matches. If STK [M] is fully matched with D [N], Flexibility [K] <- flexibility [k] 1 does not match, there is flexibility [k] <- flexibility [k] 0 (4) to eliminate the selection Keep a test with high fitness.

转载请注明原文地址:https://www.9cbs.com/read-33908.html

New Post(0)