Function PGARestrictedTournamentReplacement

Function Documentation

void PGARestrictedTournamentReplacement(PGAContext *ctx)

Perform restricted tournament replacement.

Description

For each individual in PGA_NEWPOP we select a window of individuals from PGA_OLDPOP, find the one genetically most like the new candidate and replace the individual if the new candidate has better evalutation. Note that we may not use the fitness here: Fitness from two different populations are uncompareable! After this populations are swapped (exchange of PGA_NEWPOP and PGA_OLDPOP) for further processing.

Example

PGAContext *ctx;

...
PGARestrictedTournamentReplacement (ctx);

Parameters
  • ctx – context variable

Returns

None