Changeset 319 for cpp/frams/genetics
- Timestamp:
- 02/01/15 01:08:50 (10 years ago)
- Location:
- cpp/frams/genetics
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
cpp/frams/genetics/f1/conv_f1.cpp
r286 r319 18 18 { 19 19 public: 20 Builder(const char*g,int mapping=0):invalid(0),genbegin(g),usemapping(mapping), energ(0),energ_div(0),first_part_mapping(NULL) {}20 Builder(const char*g,int mapping=0):invalid(0),genbegin(g),usemapping(mapping),first_part_mapping(NULL),energ(0),energ_div(0) {} 21 21 ~Builder() {SAFEDELETE(first_part_mapping);} 22 22 char tmp[222]; -
cpp/frams/genetics/f9/conv_f9.cpp
r286 r319 91 91 int GenoConv_f90::findVertexAt(vector<XYZ_LOC> &vertices, const XYZ_LOC &vertex) 92 92 { 93 for ( int i = 0; i < vertices.size(); i++)93 for (size_t i = 0; i < vertices.size(); i++) 94 94 if (vertices[i].same_coordinates(vertex)) return i; 95 95 return -1; -
cpp/frams/genetics/f9/oper_f9.cpp
r286 r319 30 30 if (!gene[0]) return 1; //empty is not valid 31 31 bool ok = true; 32 int i;32 size_t i; 33 33 for (i = 0; i < strlen(gene); i++) if (!strchr(turtle_commands_f9, gene[i])) { ok = false; break; } 34 34 return ok ? GENOPER_OK : i + 1; … … 39 39 { 40 40 SString validated; //new genotype (everything except turtle_commands_f9 is skipped) 41 for ( int i = 0; i < strlen(gene); i++)41 for (size_t i = 0; i < strlen(gene); i++) 42 42 if (strchr(turtle_commands_f9, gene[i])) validated += gene[i]; //validated contains only turtle_commands_f9 43 43 free(gene); -
cpp/frams/genetics/fF/conv_fF.cpp
r286 r319 104 104 double pcx = chambers[which - 1]->centerX; 105 105 double pcy = chambers[which - 1]->centerY; 106 double pcz = chambers[which - 1]->centerZ;106 //double pcz = chambers[which - 1]->centerZ; //not used 107 107 108 108 /* aperture of the next to last chamber */ 109 109 double ppx; 110 110 double ppy; 111 double ppz;111 //double ppz; //not used 112 112 113 113 if (which == 1) … … 115 115 ppx = pcx; 116 116 ppy = pcy; 117 ppz = pcz;117 //ppz = pcz; 118 118 } 119 119 else … … 121 121 ppx = chambers[which - 2]->holeX; 122 122 ppy = chambers[which - 2]->holeY; 123 ppz = chambers[which - 2]->holeZ;123 //ppz = chambers[which - 2]->holeZ; 124 124 } 125 125 -
cpp/frams/genetics/fT/oper_fTest.cpp
r286 r319 65 65 if (!gene[0]) return 1; //empty is not valid 66 66 bool ok = true; 67 int i;67 size_t i; 68 68 for (i = 0; i < strlen(gene); i++) if (!strchr("ATGC", gene[i])) { ok = false; break; } 69 69 return ok ? GENOPER_OK : i + 1; … … 74 74 { 75 75 SString validated; //new genotype (everything except ATGC is skipped) 76 for ( int i = 0; i < strlen(gene); i++)76 for (size_t i = 0; i < strlen(gene); i++) 77 77 if (strchr("ATGC", gene[i])) validated += gene[i]; //validated contains only ATGC 78 78 free(gene); -
cpp/frams/genetics/genman.cpp
r286 r319 101 101 GenMan::GenMan() : localpar(GMparam_tab, this), localstats(GMstats_tab, this), 102 102 seloperpar("GenOperators", "Genetics: Active operators"), 103 par("GenMan", "Manages various genetic operations, using appropriate operators for the argument genotype format."),104 neuronsparam("Genetics: Neurons to add", "neuronsAdd", "neuadd_")103 neuronsparam("Genetics: Neurons to add", "neuronsAdd", "neuadd_"), 104 par("GenMan", "Manages various genetic operations, using appropriate operators for the argument genotype format.") 105 105 { 106 106 history = 0;
Note: See TracChangeset
for help on using the changeset viewer.