Utilities
Parameters
Experiment ━━ Genus ━━ Species ━━ Organism ━━ Genotype ━━ Chromosome ━━ Node
┗━━━━ Phenotype
┗━━━━━ Link
An Experiment
drives the evolution of a Genus
.
int MPI_rank
This Experiment
's MPI rank returned by MPI_Comm_size
.
int MPI_size
The total number of MPI processes returned by MPI_Comm_rank
.
std::vector<int> MPI_counts
std::vector<int> MPI_displacements
The counts and displacements required by MPI_Allgatherv
.
std::vector<Vertex> vertexes
Stores the Vertex
es which define this Experiment
's starting minimal Graph
.
std::vector<Edge> edges
Stores the Edge
s which define this Experiment
's starting minimal Graph
.
static std::vector<std::vector<std::vector<double>>> stimuli
Contains the stimuli presented to the Organism
s throughout the evolutionary process.
Genus* genus
Points to the Genus
to be evolved by this Experiment
.
Experiment()
Constructs an empty Experiment
.
~Experiment()
Destructs the Experiment
, as well as its Genus
.
void run()
Runs this Experiment
.
virtual void display()
Displays any of this Experiment
's properties.
void score()
Uses MPI to score all Organism
s in parallel.
virtual double fitness(Organism* organism_) = 0
Evaluates the referenced input Organism
's fitness score.