#include <genetics.h>
Inheritance diagram for DiploidGenome:
Public Methods | |
virtual void | init () |
virtual void | addPrivateGenes (Gentainer &g, const StringMap ¶ms) |
virtual int | length () const |
virtual bool | pointMutate (const MutationRate &k) |
virtual void | recombine (const Genstruct &a, const Genstruct &b) |
virtual double | equality (const Genstruct &other) const |
virtual Genstruct * | replicate () const |
virtual void | copy (const Genstruct &other) |
virtual void | print (TextOStream &out) const |
Protected Methods | |
virtual int | calc_len () const |
Definition at line 611 of file genetics.h.
|
Implementation for Genstruct.
Reimplemented from Genome. |
|
Actually calculates the true length of the genome (recursively).
Reimplemented from Gentainer. |
|
Copies another structure to self (recursively). The other structure must be structurally EXACTLY equivalent to self (for example, replicated previously). This is cool. Reimplemented from Gentainer. |
|
Compares how genotypically similar the structure is to another. The units of the distance are usually application-dependent. One might, for example, use same euclidean distance or Hamming distance measurement with all genes, but then some genes may really be irrelevant for some problem, and they may have to be weighted. Thus, implementing this method in a generic way may be rather difficult.
Reimplemented from Gentainer. |
|
Implementation for Genstruct.
Reimplemented from Genome. |
|
Calculates recursively the total number of genes within the genetic structure.
Reimplemented from Genstruct. |
|
Mutates the structure.
Reimplemented from Gentainer. |
|
Implementation for Genstruct.
Reimplemented from Genome. |
|
Makes this structure a recombination of given parent structures. If no internal recombination actualizes within the structure, the parent 'a' must always be copied. Reimplemented from Gentainer. |
|
Clones a copy of self, RECURSIVELY. It's funny how simple reproduction is nowadays. Reimplemented from Gentainer. |