Home > Machine Learning, Projects > Genetic Algorithm – Example 1.

Genetic Algorithm – Example 1.

February 20, 2011 Leave a comment Go to comments

I quote below a personal portable implementation (in C++) of a classic genetic algorithm (evolutionary algorithm) used to maximize the function f(x) = sin(x) in the domain 0 <= x <= 2pi. You can compile the program with the g++ compiler.

The Genetic Algorithm implements the following features:

  1. Monoparametric optimization problem (with continuous parameter)
  2. Natural representation of genotypes
  3. Genotypes of only one chromosome
  4. Number of iterations as the termination criterion
  5. Elitism by cloning of the best individuals
  6. Roulette wheel method for the selection of parents
  7. Generational replacement of parents and children
  8. Average crossover and cloning of parents
  9. Mutation with disorder for producing a new solution

For more information you can get the project itself:

`evolutionary-computation-paradigms

  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: