Changeset 145 for cpp/frams/genetics/oper_fx.h
- Timestamp:
- 02/26/14 20:21:22 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
cpp/frams/genetics/oper_fx.h
r139 r145 81 81 public: 82 82 Param par; 83 char supported_format; ///<genotype format which is supported by this class ('6' for Geno _f6, etc.). Must be initialized in constructor83 char supported_format; ///<genotype format which is supported by this class ('6' for GenoOper_f6, 'F' for GenoOper_fF, etc.). Must be initialized in constructor 84 84 SString name; ///<name of this set of genetic operators 85 85 char **mutation_method_names; ///<array of names for mutation methods. If initialized (by new char*[]), must have entries for each method index returned by mutate(geno,chg,METHOD). If initialized, it is automatically freed by this destructor. … … 187 187 static double mutateCreepNoLimit(char type,double current,double mn,double mx); ///<returns \e current value creep-mutated with Gaussian distribution within [ \e mn , \e mx ] interval. Forced precision: 3 digits after comma. \e type must be either 'd' (integer) or 'f' (float/double). 188 188 static double mutateCreep(char type,double current,double mn,double mx); ///<just as mutateCreepNoLimit(), but forces mutated value into the [mn,mx] range using the 'reflect' approach. 189 static void setIntFromDoubleWithProbabilisticDithering(ParamInterface &p, int index, double value); ///<sets a double value in an integer field; when a value is non-integer, applies random "dithering" so that both lower and higher integer value have some chance to be set. 190 static void linearMix(ParamInterface &p1, int i1, ParamInterface &p2, int i2, double proportion); ///<mixes i1'th and i2'th properties of p1 and p2; proportion should be within [0,1]; 0.5 causes both properties to become their average. For integer properties applies random "dithering" when necessary. 189 191 static NeuroClass* getRandomNeuroClass(); ///<returns random neuroclass or NULL when no active classes. 190 192 static NeuroClass* parseNeuroClass(char *&s); ///<returns neuroclass or NULL if the string does not begin with a valid name. Advance \e s pointer.
Note: See TracChangeset
for help on using the changeset viewer.