1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
//! The `mutation` module provides implementation of the
//! functions for various mutation schemes for binary encoded
//! and real value encoded individuals.
//!
//! The provided functions are organized in sub-modules
//! named after the utilized mutation schema.
//!
//! Available mutation schema for binary encoded
//! individuals are:
//! * `flipping`
//! * `inversion`
//! * `scramble`
//! * `swap`
//!
//! All the mutation functions for binary encoded schema
//! take in atleast an argument of mutable reference to
//! the boolean vector of individual to mutate. Hence they
//! change the actual boolean Vector.
//!
//! Only those functions where, there is a need to constrain
//! range of values that can be provided as argument will return
//! a `Result<(), &'static str>`. The returned value should be checked
//! in case `Err` was returned because of invalid argument values.
//!
//! Available mutation schema for real value encoded
//! individuals are:
//! * `random`
//! * `polynomial`
//!
//! All the mutation functions for real value encoded schema
//! take in the floating point value of individual and return
//! the mutated value.
// Re-exports
pub use flipping_mutation;
pub use inversion_mutation;
pub use polynomial_mutation;
pub use random_mutation;
pub use scramble_mutation;
pub use swap_mutation;