public class GeneticAlgorithmSteady extends GeneticAlgorithm
GeneticAlgorithmSteady is the genetic algorithm (GA) algorithm when
the steady option is chosen, that is, the Steady parameter of the
given method is marked.
This class is an specification of GeneticAlgorithm
.
Constructor and Description |
---|
GeneticAlgorithmSteady(GeneticIndividual initialIndividual,
int pPopSize,
int pGenerations,
int pTourSize,
double PM,
double AMP,
double PMG,
double pLOptProb,
int NOL,
int IOL,
Randomize r,
int pCrossoverID,
int pMutationID)
Class constructor with the following parameters:
|
Modifier and Type | Method and Description |
---|---|
GeneticIndividual |
evolve(int MAXITER)
this method is intended for evolving the algorithm for a given number of iterations
with an steady GA algorithm.
|
public GeneticAlgorithmSteady(GeneticIndividual initialIndividual, int pPopSize, int pGenerations, int pTourSize, double PM, double AMP, double PMG, double pLOptProb, int NOL, int IOL, Randomize r, int pCrossoverID, int pMutationID)
Class constructor with the following parameters:
initialIndividual
- a GeneticIndividual
to start the search process with the desired type of individualpPopSize
- an int with the population sizepGenerations
- an int with the number of iterations to be carried outpTourSize
- an int with the number of individuals that must be chosen for the tournamentPM
- a double with the mutation probabilityAMP
- a double with the mutation amplitudePMG
- a double with the migration probabilitypLOptProb
- a double with the local optimization method probabilityNOL
- an int with the number of iterations in the local optimization methodIOL
- an int with the local identification method identidicationr
- the Randomize
objectpCrossoverID
- the genetic algorithm crossover operation used attending the the current GenotypepMutationID
- the genetic algorithm crossover operation used attending the the current Genotypepublic GeneticIndividual evolve(int MAXITER) throws invalidCrossover, invalidMutation, invalidOptim
this method is intended for evolving the algorithm for a given number of iterations with an steady GA algorithm. The basic steps for each iteration are: the tournament selection and the genetic operations are carried out, the offsprings are evaluated and sorted with the current population.
evolve
in class GeneticAlgorithm
MAXITER
- an integer with the number of iterations torun in the evolucionGeneticIndividual
foundinvalidCrossover
- in case of unsupported crossover.invalidMutation
- in case of unsupported mutation.invalidOptim
- in case of local optimization operations..