|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectOperator.Operations.SelectionOperation
jeco.kernel.algorithm.moge.TournamentSelectMO
public class TournamentSelectMO
The operation of this class is tournament selection. The individual with the best fitness from a randomly selected tournament of size tournamentSize is cloned to the selected population.
Field Summary | |
---|---|
protected double |
pressureModifier
|
protected Util.Random.RandomNumberGenerator |
rng
|
protected java.util.List<Individuals.Individual> |
tour
|
protected int |
tournamentSize
|
Fields inherited from class Operator.Operations.SelectionOperation |
---|
selectedPopulation, size |
Constructor Summary | |
---|---|
TournamentSelectMO()
New instantion |
|
TournamentSelectMO(Util.Random.RandomNumberGenerator rand,
java.util.Properties p)
Creates a new instance of TournamentSelect |
Method Summary | |
---|---|
void |
doOperation(Individuals.Individual indvdl)
|
void |
doOperation(java.util.List<Individuals.Individual> operands)
Individuals from operands will be added to the selected population if they win their tournament. |
Util.Random.RandomNumberGenerator |
getRNG()
|
void |
getTour(java.util.List<Individuals.Individual> operands)
Adds individual to the tournament by randomly selecting from the operands untill the touramentSize is reached. |
void |
selectFromTour()
Select a winner from the tournament and add to the selected population. |
void |
setProperties(java.util.Properties p)
|
void |
setRNG(Util.Random.RandomNumberGenerator m)
|
Methods inherited from class Operator.Operations.SelectionOperation |
---|
getSelectedPopulation, getSize |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected Util.Random.RandomNumberGenerator rng
protected int tournamentSize
protected double pressureModifier
protected java.util.List<Individuals.Individual> tour
Constructor Detail |
---|
public TournamentSelectMO(Util.Random.RandomNumberGenerator rand, java.util.Properties p)
rand
- random number generatorp
- properties (including tournament size)public TournamentSelectMO()
Method Detail |
---|
public final void setProperties(java.util.Properties p)
setProperties
in interface Parameter.ParameterI
setProperties
in class Operator.Operations.SelectionOperation
public void doOperation(java.util.List<Individuals.Individual> operands)
doOperation
in interface Operator.Operations.Operation
doOperation
in class Operator.Operations.SelectionOperation
operands
- Individuals to be selected frompublic void getTour(java.util.List<Individuals.Individual> operands)
operands
- Individuals that can be selected to the tournamentpublic void selectFromTour()
public void setRNG(Util.Random.RandomNumberGenerator m)
setRNG
in interface Util.Random.Stochastic
public Util.Random.RandomNumberGenerator getRNG()
getRNG
in interface Util.Random.Stochastic
public void doOperation(Individuals.Individual indvdl)
doOperation
in interface Operator.Operations.Operation
doOperation
in class Operator.Operations.SelectionOperation
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |