Databases Reference
In-Depth Information
and the elements of the two parents before and after the crossover position
are exchanged.
Mutation: The mutation operator alters one or more values of the allele
in the cromosome in order to increase the structural variability. This
operator is the major instrument of any particular area of the entire
search space. Survival step is required to choose the cromosomes for
next generation. Unlike selection and crossover phase, it is not always
mandatory to work out this phase. This phase is needed for selecting the
cromosomes from parent population as well as children population by
fitting some random numbers.
GA can solve optimization problems having a lot of constraints because
there is a very few chance of falling in local optima. An optimization
problem is a problem, where we have to maximize/minimize a function
of the kind f ( x 1 ,x 2 ,...,x m )where( x 1 ,x 2 ,...,x m ) are variables, which
have to be adjusted towards a global optimum. The bit strings of the
variables are then concatenated together to produce a single bit string
(cromosome) which represents the whole vector of the variables of the
problem. In biological terminology, each bit position represents a gene of
the cromosome, and each gene may take on some number of values called
alleles.
The search begins with an initial population comprising of a fixed
number of chromosomes. On the initial population, genetic operations are
carried out large number of times. The stopping criterion can be based
on considerations such as number of iterations, quality of the solution front
namely convergence, diversity etc. At the end of iteration, inferior solutions
are discarded and superior solutions are selected for reproduction [4].
10.4. Path Wise Test Data Generation Based on GA
Automatic test data generation strategy based on GA is explained in this
section through an example. For better understanding of the procedure, test
data are generated for the control flow graph given in Fig. 10.2(b). This
example along with the experimental results are taken from Sthamer. 7
The most important parameters of GA(for this case) are given below:
Selection of parents for recombination is random .
The mutated genes (Bits) are marked bold in off spring population.
Fitness is calculated according to reciprocal fitness function.
Search WWH ::




Custom Search