Struct ai::chromosome::Chromosome [] [src]

pub struct Chromosome { /* fields omitted */ }

A chromosome struct to be used to generate binary genes.

Methods

impl Chromosome
[src]

new() instantiates a new Chromosome. It has 44 genes (0 or 1) in a vector

fitness is the adaptability of the respective chromosome. Fitness should be between 0 and 1, where 1 is best.

During the evolution process a chromosome should mutate. Chromosomes should be able to mutate during the eveolution process

Trait Implementations

impl Debug for Chromosome
[src]

Formats the value using the given formatter.