Genetic Algorithms

Eli Frigo + Clive Moras

Fundamentals of Genetic Algorithms

Key components

  1. Population

    Population is a subset of solutions in the current generation. It can also be defined as a set of chromosomes. There are several things to be kept in mind when dealing with GA population. The diversity of the population should be maintained otherwise it might lead to premature convergence. The population size should not be kept very large as it can cause a GA to slow down, while a smaller population might not be enough for a good mating pool. Therefore, an optimal population size needs to be decided by trial and error.

  2. Fitness function

    The fitness function is the function that the GA tries to maximize. The word "fitness" is taken from evolutionary theory. It is used here because the fitness function tests and quantifies how 'fit' each potential solution is. The fitness function is one of the most pivotal parts of the algorithm because it defines the goal that the model progresses towards.

  3. Selection

    Selection is the stage of a genetic algorithm in which individual genomes are chosen from a population for later breeding. Essentially, you choose which candidates will live to the next generation and reproduce. There are different selection algorithms you can use for selection. Retaining the best individuals in a generation unchanged in the next generation, is called elitism or elitist selection. It is a successful variant of the general process of constructing a new population

  4. Crossover

    In genetic algorithms and evolutionary computation, crossover, also called recombination, is a genetic operator used to combine the genetic information of two parents to generate new offspring. It is one way to stochastically generate new solutions from an existing population, and is analogous to the crossover that happens during sexual reproduction in biology. Solutions can also be generated by cloning an existing solution, which is analogous to asexual reproduction. Newly generated solutions may be mutated before being added to the population. Mutation is a genetic operator used to maintain genetic diversity of the chromosomes of a population of a genetic or, more generally, an evolutionary algorithm (EA). It is analogous to biological mutation.

  5. Mutation

    The classic example of a mutation operator of a binary coded genetic algorithm (GA) involves a probability that an arbitrary bit in a genetic sequence will be flipped from its original state. A common method of implementing the mutation operator involves generating a random variable for each bit in a sequence. This random variable tells whether or not a particular bit will be flipped. This mutation procedure, based on the biological point mutation, is called single point mutation. Other types of mutation operators are commonly used for representations other than binary, such as floating-point encodings or representations for combinatorial problems.

Workflow

Insert basic workflow of a genetic algorithm