mutation

inline suspend fun <V, F> PanmicticEvolveScope<V, F>.mutation(chance: Double, parallelismLimit: Int, crossinline mutation: (chromosome: Chromosome<V, F>, random: Random) -> Unit)

Performs a mutation step for population in PanmicticGA that modify in-place the input chromosomes.

Welcome to use for your own implementations! It is a base function for executing mutation step in PanmicticGA.

Parameters

chance

chance of mutation for each chromosome

parallelismLimit

limit of parallel workers

mutation

specific mutation action (How chromosomes will be mutated)