GeneticTS / docsProject documentation

Explanation

Project context and scope

Understand the design decisions, alternatives, and limits.

  1. 01Velocities
  2. 02Physics rollouts
  3. 03Rank fitness
  4. 04Breed & mutate
  5. 05Next generation
GeneticTS at a glance. Follow the responsibilities across the system; use the reference pages for precise contracts.

A browser simulation where a population of launch velocities evolves under Matter.js physics, wind, gravity, mutation, and draggable targets.

Genetic Algorithms in TypeScript is an interactive simulation that evolves launch velocities for a ball trying to hit a target in a bounded physics scene. Each genome is a two-dimensional initial velocity. The simulator evaluates a generation by replaying every genome through Matter.js, scoring hits, minimum distance, and path behavior, then breeding the next generation through elitism, rank-biased parent selection, blend crossover, mutation, and random resets. The UI exposes the important algorithm and environment parameters so convergence changes are visible when gravity, wind, population size, mutation rate, elite share, target size, or the target position changes.