Genetic Algortihm

Started by
7 comments, last by CProgrammer 20 years ago
I have created a Genetic Algorithm and all is fine so far. However I need more genetic diversity. Anybody have any good articles on how to achieve good genetic diversity. I know a low Mutation rate and a small tournament size help, but thats not enough. -CProgrammer
Advertisement
Implement an "Angel of Death". Some sort of pass over the population that happens rarely but once in a while where you randomly kill off entities or whatever objects you have competing for no reason. This increases chance of diversity too and usually needed in genetic AI because you get situation where you reach a local maximum and need to break it down to find a better solution.

~Wave

[edited by - Wavewash on March 23, 2004 11:51:54 PM]
So basically just rarely replace a solution with a random new one. I''ll try that thanks.
your better of trying to test whether your population has become stagnant, either by checking how similar your chromosomes are (hamming codes or the like) or by seeing how similar all your fitness values are.

you could also try implementing more operators than just binary mutate and crossover.
the Angel of Death wasn''t random
aboeing: What operators did you have in mind.
petewood: If a random solution doesnt replace the dead one, then what. I cant have the population shrinking.
-CProgrammer
quote:Original post by CProgrammer
I have created a Genetic Algorithm and all is fine so far. However I need more genetic diversity.
Anybody have any good articles on how to achieve good genetic diversity. I know a low Mutation rate and a small tournament size help, but thats not enough.
-CProgrammer


Er, no, you want a high mutation rate. High mutation means more changes which means more diversity. Low mutation means that once your algorithm starts to converge on an answer, there''s little chance of finding a totally different (but better) answer.

This may be better off in the AI forum.

[ MSVC Fixes | STL Docs | SDL | Game AI | Sockets | C++ Faq Lite | Boost
Asking Questions | Organising code files | My stuff | Tiny XML | STLPort]
As the genetic diversity becomes homogenous the mutation rate becomes unity.

Think inbreeding.
- The trade-off between price and quality does not exist in Japan. Rather, the idea that high quality brings on cost reduction is widely accepted.-- Tajima & Matsubara
quote:Original post by Kylotan
Er, no, you want a high mutation rate.

This may be better off in the AI forum.

Agreed.

You can introduce more ''randomness'' by both adding different operators, and different selection schemes.
If you use a random selection scheme, you should end up with more random individuals.

Other operators you can try are non-binary operators, like average, and creep, and double or more point crossovers.

You could also just add a few random individuals into your population, and then use a random selection scheme, as that will let you control the ammount of randomness introduced quite nicely.

This topic is closed to new replies.

Advertisement