p
ga
package ga
Ordering
- Alphabetic
Visibility
- Public
- Protected
Type Members
- final case class AlgoSettings[A](maxPopulationSize: Int, maxGenerations: Int, success: (A) => Boolean, mutate: (Seed, A, Generation, Offset) => (Seed, Option[A]), combine: (Seed, A, A) => (Seed, A))(implicit evidence$1: Ordering[A], evidence$2: Show[A]) extends Product with Serializable
- maxPopulationSize
the max population size to keep
- maxGenerations
the maximum number of generations to run
- success
a predicate to determine if 'A' satisfies the success criteria
- mutate
a function which can optionally mutate a record
- combine
a function which can combine two records given a random seed
- sealed trait Geneology[A] extends AnyRef
- case class Mutation[A](value: A, original: Offspring[A])(implicit evidence$3: Show[A]) extends Geneology[A] with Product with Serializable
- final case class Node(id: String, label: String, color: String, parents: Set[Node]) extends Product with Serializable
- case class Offspring[A](value: A, generation: Int, offspringNr: Int, mom: Geneology[A], dad: Geneology[A])(implicit evidence$2: Show[A]) extends Geneology[A] with Product with Serializable
- case class Origin[A](value: A)(implicit evidence$1: Show[A]) extends Geneology[A] with Product with Serializable
- final case class Seed(long: Long) extends Product with Serializable
Value Members
- object AlgoSettings extends Serializable
- object GeneticAlgo
1) start with an initial population, represented as Seq[A] 2) sort on fitness 3) if there is a solution, good times, else ...
1) start with an initial population, represented as Seq[A] 2) sort on fitness 3) if there is a solution, good times, else ... 4) reproduce - "mate" each entry with another within a certain proximity. we will end up with another Seq[A] with the offspring 5) potentially mutate some records - again go from Seq[A] -> Seq[A]
- object HtmlRenderer
- object Node extends Serializable
- object Seed extends Serializable