This project implements a Genetic Algorithm (GA) in C++ to solve a multidimensional data clustering optimization problem.
It was developed during university laboratory sessions, where the task included extending a provided baseline library with custom GA logic and performing live refactoring of the core algorithm.
- Generates the initial population
- Implements selection and crossover mechanisms
- Evaluates fitness values
- Runs the main evolutionary loop
- Stores the genotype representation
- Implements genetic operators:
- Crossover
- Mutation
A core requirement of the lab was a live refactoring of the crossover operator:
- Original implementation: Single-Point Crossover
- Refactored into: Modular Uniform Crossover
- Current state:
- The refactored Uniform Crossover is the active implementation
- The original Single-Point Crossover remains in the code as commented-out reference
This approach demonstrates refactoring skills and preserves the previous logic for comparison and further development.
The following files were supplied as the foundation of the project, defining:
- the problem space,
- the evaluation metric,
- data point representation.
GroupingEvaluator.cpp / .hGaussianGroupingEvaluatorFactory.cpp / .hPoint.cpp / .h