Introduction

When the search space is extremely large, trying every possible solution can be a nightmare.

To address this, in the 1960s, a computer scientist named John Holland borrowed an idea from Darwin's theory of evolution and introduced the Genetic Algorithm. Instead of calculating the optimal answer directly, this algorithm starts from a population of random candidate solutions and gradually improves them through selection, crossover, and mutation. The result is an adaptive search algorithm capable of finding strong solutions to global optimization problems.

Source: https://www.generativedesign.org/02-deeper-dive/02-04_genetic-algorithms/02-04-01_what-is-a-genetic-algorithm

Source: https://www.generativedesign.org/02-deeper-dive/02-04_genetic-algorithms/02-04-01_what-is-a-genetic-algorithm


Intuition and Biological Metaphor

Instead of directly calculating the final optimal solution, GA:

  1. Generate a bunch of random guesses
  2. Keep the ones that work best
  3. Combine and modify them to make new guesses
  4. Repeat

To map biology onto code: