C# Class AForge.Genetic.GPCustomTreeNode

Represents tree node of genetic programming tree.

In genetic programming a chromosome is represented by a tree, which is represented by GPTreeChromosome class. The GPTreeNode class represents single node of such genetic programming tree.

Each node may or may not have children. This means that particular node of a genetic programming tree may represent its sub tree or even entire tree.

Inheritance: ICloneable
Afficher le fichier Open project: stefan-j/GeneticMIDI Class Usage Examples

Méthodes publiques

Свойство Type Description
Children List
Gene IGPGene

Méthodes publiques

Méthode Description
Clone ( ) : object

Clone the tree node.

GPCustomTreeNode ( IGPGene gene ) : System

Initializes a new instance of the GPTreeNode class.

Generate ( IEnumerable notes ) : void
GenerateNotes ( ) : List
Repeat ( int n ) : GPCustomTreeNode
ShiftDuration ( int val ) : void
ShiftPitch ( int val ) : void
Swap ( ) : void
ToString ( ) : string

Get string representation of the node.

String representation of the node lists all node's children and then the node itself. Such node's string representations equals to its reverse polish notation.

For example, if nodes value is '+' and its children are '3' and '5', then nodes string representation is "3 5 +".

Private Methods

Méthode Description
GPCustomTreeNode ( ) : System

Initializes a new instance of the GPTreeNode class.

Method Details

Clone() public méthode

Clone the tree node.
public Clone ( ) : object
Résultat object

GPCustomTreeNode() public méthode

Initializes a new instance of the GPTreeNode class.
public GPCustomTreeNode ( IGPGene gene ) : System
gene IGPGene
Résultat System

Generate() public méthode

public Generate ( IEnumerable notes ) : void
notes IEnumerable
Résultat void

GenerateNotes() public méthode

public GenerateNotes ( ) : List
Résultat List

Repeat() public méthode

public Repeat ( int n ) : GPCustomTreeNode
n int
Résultat GPCustomTreeNode

ShiftDuration() public méthode

public ShiftDuration ( int val ) : void
val int
Résultat void

ShiftPitch() public méthode

public ShiftPitch ( int val ) : void
val int
Résultat void

Swap() public méthode

public Swap ( ) : void
Résultat void

ToString() public méthode

Get string representation of the node.

String representation of the node lists all node's children and then the node itself. Such node's string representations equals to its reverse polish notation.

For example, if nodes value is '+' and its children are '3' and '5', then nodes string representation is "3 5 +".

public ToString ( ) : string
Résultat string

Property Details

Children public_oe property

List of node's children.
public List Children
Résultat List

Gene public_oe property

Gene represented by the chromosome.
public IGPGene Gene
Résultat IGPGene