Exemple #1
0
 internal Genome(SwarmEngineSettings <TMainModel, TCombinationModel> settings)
 {
     Genes     = new List <Gene <TCombinationModel> >();
     _settings = settings;
     _model    = settings.CreateModelFunc();
     Id        = Counter++;
 }
Exemple #2
0
 internal EngineBuilder()
 {
     _settings = new SwarmEngineSettings <TModel, TCombinationModel>();
     _settings.PopulationSize = _defaultPopulationSize;
     _settings.CrossoverRate  = 0;   //_defaultCrossoverRate;
     _settings.MutationRate   = 0.8; //_defaultMutationRate;
     _settings.GenomeLength   = 1;   // 1 gene per genome, a gene contains enabled combinations
 }
Exemple #3
0
 internal Chromosone(SwarmEngineSettings <TMainModel, TCombinationModel> settings)
 {
     Genomes   = new List <Genome <TMainModel, TCombinationModel> >();
     _settings = settings;
 }