[Quantproject-developers] QuantProject/b1_ADT/Optimizing/Genetic Genome.cs, 1.16, 1.17
Brought to you by:
glauco_1
|
From: Marco M. <mi...@us...> - 2007-06-20 14:57:08
|
Update of /cvsroot/quantproject/QuantProject/b1_ADT/Optimizing/Genetic In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv9810 Modified Files: Genome.cs Log Message: Fixed bug in get method for the Fitness property Deleted set method in Fitness property. Index: Genome.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b1_ADT/Optimizing/Genetic/Genome.cs,v retrieving revision 1.16 retrieving revision 1.17 diff -C2 -d -r1.16 -r1.17 *** Genome.cs 19 Jun 2007 19:18:38 -0000 1.16 --- Genome.cs 20 Jun 2007 14:56:59 -0000 1.17 *************** *** 70,80 **** if ( ! this.hasFitnessBeenAssigned ) // the genome's fitness has not been assigned yet this.fitness = this.genomeManager.GetFitnessValue(this); ! return this.fitness; ! } ! set ! { ! this.fitness = value; ! this.hasFitnessBeenAssigned = true; } } --- 70,78 ---- if ( ! this.hasFitnessBeenAssigned ) // the genome's fitness has not been assigned yet + { this.fitness = this.genomeManager.GetFitnessValue(this); ! this.hasFitnessBeenAssigned = true; ! } ! return this.fitness; } } *************** *** 86,96 **** if ( this.meaning == null ) // the genome's meaning has not been assigned yet ! this.meaning = this.genomeManager.Decode( this ); return this.meaning; } - set - { - this.meaning = value; - } } --- 84,90 ---- if ( this.meaning == null ) // the genome's meaning has not been assigned yet ! this.meaning = this.genomeManager.Decode( this ); return this.meaning; } } *************** *** 172,177 **** Genome returnValue = new Genome(this.genomeManager, this.geneticOptimizer); returnValue.CopyValuesInGenes(this.genes); ! returnValue.Fitness = this.Fitness; ! returnValue.Meaning = this.Meaning; returnValue.generation = this.Generation; returnValue.hasBeenCloned = true; --- 166,171 ---- Genome returnValue = new Genome(this.genomeManager, this.geneticOptimizer); returnValue.CopyValuesInGenes(this.genes); ! returnValue.fitness = this.fitness; ! returnValue.meaning = this.meaning; returnValue.generation = this.Generation; returnValue.hasBeenCloned = true; |