Skip to content

Commit 3d70ff0

Browse files
committed
Add remark about RangeGenotype being able to permutate when scaled
1 parent f5dd645 commit 3d70ff0

File tree

5 files changed

+5
-5
lines changed

5 files changed

+5
-5
lines changed

src/genotype.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@ pub trait HillClimbGenotype: Genotype {
227227
}
228228

229229
/// Genotype suitable for [Permutate](crate::strategy::permutate::Permutate).
230-
/// Not all genotypes are permutable, only countable ones (e.g. range genotypes cannot be permutated).
230+
/// Not all genotypes are permutable, only countable ones (e.g. range genotypes cannot be permutated, unless scaled).
231231
pub trait PermutateGenotype: Genotype {
232232
/// chromosome iterator for the all possible gene combinations for [Permutate](crate::strategy::permutate::Permutate)
233233
fn chromosome_permutations_into_iter<'a>(

src/genotype/dynamic_matrix.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ pub type DefaultAllele = f32;
3333
/// This is a simple heap based example implementation. The size doesn't need to be known up front,
3434
/// as de storage extend if needed.
3535
///
36-
/// The rest is like [RangeGenotype](super::RangeGenotype):
36+
/// The rest is like [RangeGenotype](super::RangeGenotype), but it cannot be permutated:
3737
///
3838
/// The values are taken from the allele range. On random initialization, each gene gets a value
3939
/// from the allele_range with a uniform probability. Each gene has an equal probability of

src/genotype/static_matrix.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ use std::ops::{Bound, Range, RangeBounds, RangeInclusive};
2929
/// [calculate_for_population](crate::fitness::Fitness::calculate_for_population) instead of
3030
/// [calculate_for_chromosome](crate::fitness::Fitness::calculate_for_chromosome).
3131
///
32-
/// The rest is like [RangeGenotype](super::RangeGenotype):
32+
/// The rest is like [RangeGenotype](super::RangeGenotype), but it cannot be permutated:
3333
///
3434
/// The values are taken from the allele range. On random initialization, each gene gets a value
3535
/// from the allele_range with a uniform probability. Each gene has an equal probability of

src/strategy.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
//! * fallback to `call_par_repeatedly(usize)` for HillClimb
2424
//!
2525
//! *Note: Only Genotypes which implement all strategies are eligable for the superset builder.*
26-
//! *RangeGenotype and other floating point range based genotypes currently do not support Permutation*
26+
//! *RangeGenotype and other floating point range based genotypes currently do not support Permutation unless scaled*
2727
//!
2828
//! Example:
2929
//! ```

src/strategy/builder.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ use crate::strategy::{Strategy, StrategyReporter, StrategyReporterNoop, Strategy
1313
/// The superset builder for all strategies.
1414
///
1515
/// *Note: Only Genotypes which implement all strategies are eligable for the superset builder.*
16-
/// *RangeGenotype and other floating point range based genotypes currently do not support Permutation*
16+
/// *RangeGenotype and other floating point range based genotypes currently do not support Permutation unless scaled*
1717
#[derive(Clone, Debug)]
1818
pub struct Builder<
1919
G: EvolveGenotype + HillClimbGenotype + PermutateGenotype,

0 commit comments

Comments
 (0)