1
$\begingroup$

I was trying to understand the principle of a GA and implemented it myself for some games and always got to the following question;

Usually the evolving of a generations works the following:

  1. testing all networks
  2. scoring them
  3. select the best
  4. reproduce the next generation
  5. mutate the next generation

In most tutorials / explanations, the mutate step is done with EVERY network.

Wouldn't it make more sense to only mutate those who just got reproduced?

This way, you could keep those who did fine without mutating them. If the next generation would be really bad, there would still be this "backup" of networks in the current generation.

Why is the mutation step applied to every network and not only just those which were newly reproduced?

$\endgroup$
2
$\begingroup$

Genetic Algorithms (GA) are inspired by Nature. In Nature all individuals are exposed (to some extent) to external influences (e.g. radiation from the sun).

Random mutations represent the effect of these external influences (aka "nurture" aka "environmental factors") on the individuals in the population.

Mutations can be beneficial and prevent populations from becoming "locked into" a confined set of characteristics.

Therefore:

Q.1. Wouldn't it make more sense to only mutate those who just got reproduced?

No, as external influences do not only occur during, or right after, reproduction. Further, any one of those mutations could potentially be beneficial, do very little, or be degenerative. The beneficial ones will be positively selected into future generations; while the degenerative mutations will be selected against.

Q.2. Why is the mutation step applied to every network and not only just those which were newly reproduced?

Because GAs are inspired by Nature.

Feel free, however, to play around with these assumptions as you like. You can be Mother Nature in your code.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.