refactor UF_random_generator to fit the new std::shuffle
This commit is contained in:
parent
009ef5e1d8
commit
4ee48e760b
7 changed files with 39 additions and 29 deletions
|
|
@ -43,7 +43,7 @@ int main()
|
|||
unsigned i;
|
||||
|
||||
// a chromosome randomizer
|
||||
eoInitPermutation <Chrom> random(CHROM_SIZE);
|
||||
eoInitPermutation <Chrom> randomize(CHROM_SIZE);
|
||||
|
||||
// the population:
|
||||
eoPop<Chrom> pop;
|
||||
|
|
@ -55,7 +55,7 @@ int main()
|
|||
{
|
||||
Chrom chrom(CHROM_SIZE);
|
||||
std::cout << " Initial chromosome n°" << i << " : " << chrom << "..." << std::endl;
|
||||
random(chrom);
|
||||
randomize(chrom);
|
||||
eval(chrom);
|
||||
std::cout << " ... becomes : " << chrom << " after initialization" << std::endl;
|
||||
check_permutation(chrom);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue