Package-level declarations

Functions

Link copied to clipboard
fun mutationFlipBit(value: BooleanArray, chance: Double, random: Random)

Flip the value of the attributes of the input chromosome. The chromosome is expected to be a BooleanArray. This mutation is usually applied on boolean individuals.

fun mutationFlipBit(value: IntArray, chance: Double, random: Random)

Flip the value of the attributes of the input chromosome. The chromosome is expected to be a IntArray with only 1 or 0 values. For other values, correct behavior is not guaranteed. Note! This mutation is usually applied on BooleanArray.

Link copied to clipboard
fun mutationGaussian(value: DoubleArray, mean: Double, stddev: Double, chance: Double, random: Random)

Applies a gaussian mutation of mean mean and standard deviation stddev on the input chromosome. This mutation expects Chromosome.value of floating point numbers.

Link copied to clipboard
fun mutationPolynomialBounded(value: DoubleArray, eta: Double, low: Double, up: Double, chance: Double, random: Random)

Polynomial mutation as implemented in original NSGA-II algorithm in C by Deb. This mutation expects Chromosome.value of floating point numbers.

Link copied to clipboard
fun <T> mutationShuffleIndexes(value: Array<T>, chance: Double, random: Random)
fun mutationShuffleIndexes(value: BooleanArray, chance: Double, random: Random)
fun mutationShuffleIndexes(value: ByteArray, chance: Double, random: Random)
fun mutationShuffleIndexes(value: CharArray, chance: Double, random: Random)
fun mutationShuffleIndexes(value: DoubleArray, chance: Double, random: Random)
fun mutationShuffleIndexes(value: FloatArray, chance: Double, random: Random)
fun mutationShuffleIndexes(value: IntArray, chance: Double, random: Random)
fun mutationShuffleIndexes(value: LongArray, chance: Double, random: Random)
fun mutationShuffleIndexes(value: ShortArray, chance: Double, random: Random)
fun <T> mutationShuffleIndexes(value: MutableList<T>, chance: Double, random: Random)

Executes a shuffle the attributes of the input chromosome. Usually this mutation is applied on vector of indices.

Link copied to clipboard
fun mutationUniform(value: DoubleArray, low: Double, up: Double, chance: Double, random: Random)
fun mutationUniform(value: IntArray, low: Int, up: Int, chance: Double, random: Random)
fun mutationUniform(value: LongArray, low: Long, up: Long, chance: Double, random: Random)

Executes a uniform mutation for the attributes of the input chromosome.