Struct genetic_planner::genetic::Individual [] [src]

pub struct Individual<T: 'static> {
    pub genes: Vec<T>,
}

Rappresent a candidate solution for the problem

Fields

Methods

impl<T> Individual<T> where
    T: Clone + Rand + Send + Sync + PartialEq + 'static, 
[src]

Create a new individual which contains a vector of genenumber of random initiliazed T

Create a new individual from a vector of T

Return an Individual which is the result of the crossover operation between self and the second Individual, accordingly the uniform_rate parameter

Return an Individual which is the result of the mutate operation, accordingly the mutation_rate parameter

Trait Implementations

impl<T: Debug + 'static> Debug for Individual<T>
[src]

Formats the value using the given formatter.

impl<T: Clone + 'static> Clone for Individual<T>
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl<T: PartialEq + 'static> PartialEq for Individual<T>
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.