[380] | 1 | expdef:
|
---|
[406] | 2 | name:Reproduction of benthic foraminifera
|
---|
[380] | 3 | info:~
|
---|
[434] | 4 | Basic information about this simulation:
|
---|
| 5 | www.framsticks.com/foraminifera
|
---|
| 6 |
|
---|
| 7 | Technical information:
|
---|
[476] | 8 | Genes and parameter values which control reproduction are stored in data->genes and data->lifeparams fields.
|
---|
[380] | 9 |
|
---|
[476] | 10 | genes:
|
---|
[402] | 11 | genes which are not encoded in Ff genotype:
|
---|
[422] | 12 | min_repro_energy - Minimum energy necessary for reproduction
|
---|
| 13 | hibernation - Defines foram behavior in the case of no nutrients
|
---|
[380] | 14 |
|
---|
[476] | 15 | lifeparams:
|
---|
[380] | 16 | Physiological parameters of foraminifera:
|
---|
[422] | 17 | max_energy_level - maximum energy level reached so far
|
---|
[380] | 18 | gen - generation: 0 haploid, 1 diploid
|
---|
[432] | 19 | species - species: 0 not hibernating 1 hibernating
|
---|
| 20 | hibernated - 0/1 foram is/isn't hibernated
|
---|
[422] | 21 | reproduce - 0/1 foram isn't/is ready for reproduction
|
---|
[380] | 22 | ~
|
---|
| 23 | code:~
|
---|
| 24 |
|
---|
[422] | 25 | global colors;
|
---|
[493] | 26 | global curColor;
|
---|
[479] | 27 | global max_chamber_volume;
|
---|
[474] | 28 | global movePerStep;
|
---|
[479] | 29 | global reprocounter;
|
---|
[481] | 30 | global changePeriod;
|
---|
| 31 | global phase;
|
---|
[567] | 32 | global species_genes;
|
---|
| 33 | global max_chambers_def;
|
---|
| 34 | global foram_uid; //introduced because each replacement of a creature (while growing) would generate a new Creature.uid
|
---|
| 35 | global chamber_vis_denominator;
|
---|
| 36 | global curRadius;
|
---|
[590] | 37 | global nutrient_num_counter;
|
---|
| 38 | global wrldsizSquareMeters;
|
---|
[1152] | 39 | const MIN_PART_SIZE = 0.05; //to avoid exceeding the allowed Part.size range when setting radius of body parts
|
---|
[380] | 40 |
|
---|
[406] | 41 | @include "foraminifera.inc"
|
---|
[401] | 42 |
|
---|
[380] | 43 | // -------------------------------- experiment begin --------------------------------
|
---|
| 44 |
|
---|
| 45 | function onExpDefLoad()
|
---|
| 46 | {
|
---|
| 47 | // define genotype and creature groups
|
---|
| 48 | GenePools.clear();
|
---|
| 49 | Populations.clear();
|
---|
| 50 | GenePools[0].name = "Unused";
|
---|
| 51 |
|
---|
| 52 | var pop = Populations[0];
|
---|
[421] | 53 | pop.name = "Forams";
|
---|
[380] | 54 | pop.en_assim = 0;
|
---|
[1097] | 55 | pop.initial_nn_active = 0;
|
---|
| 56 | pop.initial_perf_measuring = 1;
|
---|
[380] | 57 | pop.death = 1;
|
---|
| 58 | pop.energy = 1;
|
---|
[487] | 59 | pop.selfmask = 0;
|
---|
| 60 | pop.othermask = 0;
|
---|
[401] | 61 | //pop.selfmask = 0x20002; pop.othermask = 0x10002;
|
---|
[847] | 62 | pop.perfperiod = 25;
|
---|
[1097] | 63 | pop.initial_physics_active = 0;
|
---|
[380] | 64 |
|
---|
[421] | 65 | pop = Populations.addGroup("Nutrients");
|
---|
[1097] | 66 | pop.initial_nn_active = 0;
|
---|
| 67 | pop.initial_perf_measuring = 0;
|
---|
[380] | 68 | pop.death = 1;
|
---|
| 69 | pop.energy = 1;
|
---|
[487] | 70 | pop.selfmask = 0;
|
---|
| 71 | pop.othermask = 0;
|
---|
[422] | 72 | //pop.othermask = 0x10002;
|
---|
[1097] | 73 | pop.initial_physics_active = 0;
|
---|
[380] | 74 |
|
---|
[444] | 75 | pop = Populations.addGroup("ReticulopodiaNutrients");
|
---|
[1097] | 76 | pop.initial_nn_active = 0;
|
---|
| 77 | pop.initial_perf_measuring = 0;
|
---|
[430] | 78 | pop.death = 0;
|
---|
| 79 | pop.energy = 0;
|
---|
[487] | 80 | pop.selfmask = 0;
|
---|
| 81 | pop.othermask = 0;
|
---|
[1097] | 82 | pop.initial_physics_active = 0;
|
---|
[444] | 83 |
|
---|
[422] | 84 | //world
|
---|
| 85 | SignalView.mode = 1;
|
---|
[496] | 86 | World.wrldwat = 200;
|
---|
[493] | 87 | World.wrldsiz = micronsToFrams(100000);
|
---|
[422] | 88 | World.wrldbnd = 1;
|
---|
| 89 |
|
---|
[486] | 90 | //ExpProperties.visualize = 1; //uncomment to visualize reticulopodia and indicate nutrients positions
|
---|
[444] | 91 |
|
---|
[847] | 92 | //ExpProperties.logging = 1; //uncomment to enable logging simulation parameters to log files
|
---|
[493] | 93 | ExpProperties.logPref = "";
|
---|
[401] | 94 |
|
---|
[554] | 95 | //morphology
|
---|
[1152] | 96 | ExpProperties.zone1_range = 5; //originally was micronsToFrams(1000); but this was exceeding the allowed Part.size range so was decreased to 5. TODO This change in reticulopodia size may slightly affect simulation and results, so verify/rethink/reimplement if using this expdef in further research.
|
---|
[486] | 97 | ExpProperties.zone2_range = micronsToFrams(3000);
|
---|
[567] | 98 | ExpProperties.chamber_proculus_haplo = micronsToFrams(20);
|
---|
| 99 | ExpProperties.chamber_proculus_diplo = micronsToFrams(10);
|
---|
[847] | 100 | colors = ["1.0,1.0,0.3", "1.0,0.7,0.0"]; //yellow and orange
|
---|
[579] | 101 | curColor = colors[0];
|
---|
[567] | 102 | curRadius = ExpProperties.zone1_range;
|
---|
[479] | 103 |
|
---|
[422] | 104 | //nutrients
|
---|
[486] | 105 | ExpProperties.nutrientradius = micronsToFrams(10);
|
---|
[847] | 106 | ExpProperties.energy_nut = 200 * energyFromVolume(ExpProperties.nutrientradius, 1);
|
---|
[554] | 107 |
|
---|
[380] | 108 | ExpState.totaltestedcr = 0;
|
---|
[421] | 109 | ExpState.nutrient = "";
|
---|
[567] | 110 |
|
---|
| 111 | max_chambers_def = 35;
|
---|
[569] | 112 | chamber_vis_denominator = 12;
|
---|
[493] | 113 | //addSpecies({"min_repro_energies" : [4,6]});
|
---|
| 114 | //addSpecies({"min_repro_energies" : [4,8]});
|
---|
[847] | 115 |
|
---|
[561] | 116 | //Simulator.print(create_genotype(0.2, 30, "1.0,1.0,0.0", 0.6)); //sample call
|
---|
| 117 | //Simulator.print(create_genotype(0.1, 40, "1.0,0.5,0.0", 0.1)); //sample call
|
---|
[380] | 118 | }
|
---|
| 119 |
|
---|
| 120 | @include "standard_placement.inc"
|
---|
| 121 |
|
---|
[567] | 122 | function onExpInit()
|
---|
[475] | 123 | {
|
---|
[1152] | 124 | wrldsizSquareMeters = Math.pow(framsToMicrons(World.wrldsiz) * 0.000001, 2);
|
---|
[568] | 125 | species_genes = [];
|
---|
[567] | 126 | foram_uid = 0;
|
---|
[568] | 127 | movePerStep = getMovePerStep();
|
---|
[475] | 128 |
|
---|
[567] | 129 | Populations[0].clear();
|
---|
| 130 | Populations[1].clear();
|
---|
| 131 | Populations[2].clear(); //reticulopodia and nutrients
|
---|
| 132 |
|
---|
| 133 | if (ExpProperties.max_chamber_num_haplo == max_chambers_def && ExpProperties.max_chamber_num_diplo == max_chambers_def)
|
---|
[479] | 134 | {
|
---|
[847] | 135 | max_chamber_volume = [[30403.5869594578, 52812.2546633948, 79578.5148482541, 113588.815134453, 154620.677376218, 205094.322220826, 262572.712174265, 326078.453295303, 402342.518962956, 498133.985678766, 615066.864740109, 759500.497626816, 937064.025544282, 1155915.25563075, 1429139.14079748, 1762487.92940157, 2176286.62046069, 2685795.63187845, 3316190.12127043, 4096436.04462706, 5051343.25226193, 6231980.1061213, 7687880.79524734, 9485307.02904958, 11716968.9852569, 14459866.4934433, 17836388.9853663, 22004935.7247348, 27138607.2546045, 33482425.1582986, 41336775.1280297, 50997910.7842793, 62888631.7871037, 77563060.9243464, 95659468.591964]
|
---|
| 136 | , [3430.07716920763, 6159.93090353532, 9322.94192815286, 13462.9896597283, 18399.8550832969, 24558.9218126892, 31468.8148639192, 39189.4977865513, 48404.4292075836, 60185.8639086061, 74490.6048472854, 92117.8178412275, 113852.779747083, 140714.366929552, 174450.937643841, 215250.242147183, 266323.295274072, 328858.042352538, 406552.379957238, 503526.321155323, 621060.781025019, 767240.824049468, 947210.683224091, 1169506.19906112, 1447211.61255879, 1787155.29073739, 2205627.64766244, 2723413.2837305, 3360233.53738709, 4147771.02835393, 5126445.06973928, 6328060.3331703, 7805693.278958, 9631924.72156452, 11884287.1596814]];
|
---|
[479] | 137 | }
|
---|
| 138 |
|
---|
[567] | 139 | else
|
---|
[479] | 140 | {
|
---|
[567] | 141 | max_chamber_volume = [Vector.new(), Vector.new()];
|
---|
| 142 | var density = 100;
|
---|
[847] | 143 | for (var ploid = 0; ploid < 2; ploid++)
|
---|
[567] | 144 | {
|
---|
| 145 | var rad = getPloidRadius(ploid);
|
---|
[847] | 146 | for (var cham_num = 0; cham_num < getProperty(ploid, "max_chamber_num"); cham_num++)
|
---|
[567] | 147 | {
|
---|
[847] | 148 | max_chamber_volume[ploid].add(volumeFromGeno(ploid, rad, cham_num + 1, density));
|
---|
| 149 | }
|
---|
[567] | 150 | }
|
---|
[479] | 151 | }
|
---|
[422] | 152 |
|
---|
[487] | 153 | if (species_genes.size == 0)
|
---|
[380] | 154 | {
|
---|
[487] | 155 | addSpecies({}); //default
|
---|
[380] | 156 | }
|
---|
[487] | 157 |
|
---|
| 158 | for (var spec = 0; spec < species_genes.size; spec++)
|
---|
| 159 | {
|
---|
| 160 | for (var i = 0; i < ExpProperties.foramPop; i++)
|
---|
| 161 | {
|
---|
[847] | 162 | addInitialForam(spec, i);
|
---|
[487] | 163 | }
|
---|
| 164 | }
|
---|
[380] | 165 | ExpState.totaltestedcr = 0;
|
---|
[554] | 166 |
|
---|
| 167 | reprocounter = 0;
|
---|
[590] | 168 | nutrient_num_counter = 0;
|
---|
[554] | 169 | changePeriod = 0;
|
---|
| 170 | phase = "low";
|
---|
[380] | 171 | }
|
---|
| 172 |
|
---|
| 173 | function onExpLoad()
|
---|
| 174 | {
|
---|
| 175 | for (var pop in Populations)
|
---|
| 176 | pop.clear();
|
---|
| 177 |
|
---|
| 178 | Loader.addClass(sim_params.*);
|
---|
| 179 | Loader.setBreakLabel(Loader.BeforeUnknown, "onExpLoad_Unknown");
|
---|
| 180 | Loader.run();
|
---|
| 181 |
|
---|
[421] | 182 | Simulator.print("Loaded " + Populations[0].size + " Forams and " + Populations[1].size + " nutrient objects");
|
---|
[380] | 183 | }
|
---|
| 184 |
|
---|
| 185 | function onExpLoad_Unknown()
|
---|
| 186 | {
|
---|
| 187 | if (Loader.objectName == "org") // saved by the old expdef
|
---|
| 188 | {
|
---|
| 189 | var g = Genotype.newFromString("");
|
---|
| 190 | Loader.currentObject = g;
|
---|
| 191 | Interface.makeFrom(g).setAllDefault();
|
---|
| 192 | Loader.loadObject();
|
---|
| 193 | var cr = Populations[0].add(g);
|
---|
| 194 | if (cr != null)
|
---|
| 195 | {
|
---|
[401] | 196 | //cr.rotate(0,0,Math.rnd01*Math.twopi);
|
---|
[476] | 197 | if ((typeof(g.data->genes) == "Vector") && (g.data->genes.size >= 3))
|
---|
[401] | 198 | {
|
---|
| 199 | // [x,y,energy]
|
---|
[638] | 200 | cr.move(g.data->genes[0] - cr.bboxCenter.x, g.data->genes[1] - cr.bboxCenter.y, 0);
|
---|
[476] | 201 | cr.energy = g.data->genes[2];
|
---|
[380] | 202 | }
|
---|
| 203 | else
|
---|
| 204 | {
|
---|
[638] | 205 | cr.move(Math.rnd01 * World.wrldsiz - cr.bboxCenter.x, Math.rnd01 * World.wrldsiz - cr.bboxCenter.y, 0);
|
---|
[380] | 206 | }
|
---|
| 207 | }
|
---|
| 208 | }
|
---|
| 209 | else if (Loader.objectName == "Creature")
|
---|
| 210 | {
|
---|
| 211 | Loader.currentObject = CreatureSnapshot.new();
|
---|
| 212 | Loader.loadObject();
|
---|
| 213 | Populations[0].add(Loader.currentObject);
|
---|
| 214 | }
|
---|
| 215 | }
|
---|
| 216 |
|
---|
| 217 | function onExpSave()
|
---|
| 218 | {
|
---|
| 219 | File.writeComment("saved by '%s.expdef'" % Simulator.expdef);
|
---|
| 220 |
|
---|
[401] | 221 | var tmpvec = [], i;
|
---|
[380] | 222 |
|
---|
[401] | 223 | for(var cr in Populations[1])
|
---|
[638] | 224 | tmpvec.add([cr.bboxCenter.x, cr.bboxCenter.y, cr.energy]);
|
---|
[380] | 225 |
|
---|
[421] | 226 | ExpState.nutrient = tmpvec;
|
---|
[380] | 227 | File.writeObject(sim_params.*);
|
---|
[432] | 228 | ExpState.nutrient = null; //vectors are only created for saving and then discarded
|
---|
[380] | 229 |
|
---|
| 230 | for (var cr in Populations[0])
|
---|
| 231 | File.writeObject(cr);
|
---|
| 232 | }
|
---|
| 233 |
|
---|
| 234 | // -------------------------------- experiment end --------------------------------
|
---|
| 235 |
|
---|
[567] | 236 | function volumeFromGeno(morphotype, rad, chamber_num, density)
|
---|
| 237 | {
|
---|
| 238 | var geno = create_genotype(rad, chamber_num, colors[morphotype], 1);
|
---|
[847] | 239 | var m = Model.newFromString(geno);
|
---|
| 240 | var mg = ModelGeometry.forModel(m);
|
---|
| 241 | mg.geom_density = density;
|
---|
[567] | 242 | var volumeInFrams = mg.volume();
|
---|
| 243 |
|
---|
[847] | 244 | return volumeInFrams / Math.pow(ExpProperties.scalingFactor, 3);
|
---|
[567] | 245 | }
|
---|
| 246 |
|
---|
[847] | 247 | function secToSimSteps(value_in_sec)
|
---|
| 248 | {
|
---|
| 249 | return value_in_sec / ExpProperties.secPerStep;
|
---|
[567] | 250 | }
|
---|
| 251 |
|
---|
| 252 | function volumeInMicrons(radiusInFrams)
|
---|
| 253 | {
|
---|
[847] | 254 | return 4.0 / 3.0 * Math.pi * Math.pow(framsToMicrons(radiusInFrams), 3);
|
---|
[567] | 255 | }
|
---|
| 256 |
|
---|
| 257 | function energyFromVolume(base, isRadiusInFrams)
|
---|
| 258 | {
|
---|
| 259 | if (isRadiusInFrams == 1) //radius in frams
|
---|
| 260 | {
|
---|
[847] | 261 | return ExpProperties.picoCarbonPerMikro * volumeInMicrons(base);
|
---|
[567] | 262 | }
|
---|
| 263 | else //volume in microns
|
---|
| 264 | {
|
---|
| 265 | return ExpProperties.picoCarbonPerMikro * base;
|
---|
| 266 | }
|
---|
| 267 | }
|
---|
| 268 |
|
---|
| 269 | function getMovePerStep()
|
---|
| 270 | {
|
---|
[847] | 271 | return micronsToFrams((ExpProperties.foramSpeedMmPerMin / 60) * 1000) * ExpProperties.secPerStep;
|
---|
[567] | 272 | }
|
---|
| 273 |
|
---|
| 274 | function micronsToFrams(micrometers)
|
---|
| 275 | {
|
---|
[847] | 276 | return micrometers * ExpProperties.scalingFactor;
|
---|
[567] | 277 | }
|
---|
| 278 |
|
---|
| 279 | function framsToMicrons(framsworldunits)
|
---|
| 280 | {
|
---|
[847] | 281 | return framsworldunits / ExpProperties.scalingFactor;
|
---|
[567] | 282 | }
|
---|
| 283 |
|
---|
| 284 | function getProperty(gen, prop_id)
|
---|
| 285 | {
|
---|
| 286 | var ploid = "haplo";
|
---|
| 287 | if (gen == 1) ploid = "diplo";
|
---|
| 288 | return ExpProperties.[prop_id + "_" + ploid];
|
---|
| 289 | }
|
---|
| 290 |
|
---|
| 291 | function getGene(cr, gen_id, gen_set)
|
---|
| 292 | {
|
---|
[847] | 293 | if (cr.data->lifeparams->gen == 0)
|
---|
[567] | 294 | return cr.data->genes[gen_id];
|
---|
[847] | 295 | else
|
---|
[567] | 296 | return cr.data->genes[gen_set][gen_id];
|
---|
| 297 | }
|
---|
| 298 |
|
---|
| 299 | function getPloidRadius(ploid)
|
---|
| 300 | {
|
---|
| 301 | var radius = ExpProperties.chamber_proculus_haplo;
|
---|
[847] | 302 | if (ploid == 1)
|
---|
| 303 | {
|
---|
| 304 | radius = ExpProperties.chamber_proculus_diplo;
|
---|
| 305 | }
|
---|
[567] | 306 | return radius;
|
---|
| 307 | }
|
---|
| 308 |
|
---|
| 309 | function chamberNumFromEnergy(energy, ploid)
|
---|
| 310 | {
|
---|
| 311 | var chamber_num = max_chamber_volume[ploid].size;
|
---|
| 312 | for (var i = 0; i < chamber_num; i++)
|
---|
| 313 | {
|
---|
[847] | 314 | if (energy < energyFromVolume(max_chamber_volume[ploid][i], 0))
|
---|
[567] | 315 | {
|
---|
[847] | 316 | chamber_num = i + 1;
|
---|
[567] | 317 | break;
|
---|
[847] | 318 | }
|
---|
| 319 | }
|
---|
| 320 |
|
---|
[567] | 321 | return chamber_num;
|
---|
| 322 | }
|
---|
| 323 |
|
---|
[595] | 324 | function createAndRotate(geno, rotate_min, rotate_max, pop_num)
|
---|
| 325 | {
|
---|
| 326 | var cr = Populations[pop_num].add(geno);
|
---|
[847] | 327 | cr.rotate(0, 0, Math.rndUni(rotate_min, rotate_max));
|
---|
| 328 | return cr;
|
---|
[595] | 329 | }
|
---|
| 330 |
|
---|
| 331 | //TODO unifiy addForam, foramGrow and createOffspring
|
---|
[567] | 332 | function addForam(species, iter, start_energy, ploid)
|
---|
| 333 | {
|
---|
| 334 | var chambernum = chamberNumFromEnergy(start_energy, ploid);
|
---|
| 335 | var radius = getPloidRadius(ploid);
|
---|
| 336 | var geno = create_genotype(radius, chambernum, colors[ploid], 1);
|
---|
[579] | 337 | curColor = colors[ploid];
|
---|
[847] | 338 | var cr = createAndRotate(geno, 0, 2 * Math.pi, 0);
|
---|
[567] | 339 | cr.name = "Initial creature" + species + "_" + iter;
|
---|
[588] | 340 | placeRandomlyNotColliding(cr);
|
---|
[567] | 341 | cr.energy = start_energy;
|
---|
| 342 | setGenotype({"opt" : "birth", "cr" : cr, "gen" : ploid, "species" : species, "energy0" : cr.energy, "genes" : species_genes[species], "parentsuids" : ["c0"]});
|
---|
| 343 | if (ploid == 1)
|
---|
| 344 | {
|
---|
| 345 | cr.data->genes = [cr.data->genes, cr.data->genes]; //TODO two different genes sets
|
---|
| 346 | }
|
---|
| 347 | moveReticulopodia(cr);
|
---|
| 348 | }
|
---|
| 349 |
|
---|
| 350 | function addInitialForam(species, iter)
|
---|
| 351 | {
|
---|
| 352 | var ploid = 0;
|
---|
| 353 | if (Math.rnd01 > 0.5)
|
---|
| 354 | {
|
---|
| 355 | ploid = 1;
|
---|
[847] | 356 | }
|
---|
[567] | 357 | //add new foram with random energy bewtween starting energy and reproduction threshold
|
---|
| 358 | var repro_thr = species_genes[species]->min_repro_energies[ploid];
|
---|
[847] | 359 | var start_energy = Math.rndUni(energyFromVolume(getPloidRadius(ploid), 1), repro_thr - 0.25 * repro_thr);
|
---|
| 360 | addForam(species, iter, start_energy, ploid);
|
---|
[567] | 361 | }
|
---|
| 362 |
|
---|
| 363 | //new species can be added as a dictionary with parameter values that are different than default values
|
---|
| 364 | function addSpecies(new_genes)
|
---|
| 365 | {
|
---|
[847] | 366 | species_genes.add({"min_repro_energies" : [ExpProperties.min_repro_energ_haplo, ExpProperties.min_repro_energ_diplo], "energies0" : [ExpProperties.energies0_haplo, ExpProperties.energies0_diplo], "hibernation" : 0, "morphotype" : 0});
|
---|
[567] | 367 | for (var i = 0; i < new_genes.size; i++)
|
---|
| 368 | {
|
---|
| 369 | var key = new_genes.getKey(i);
|
---|
[847] | 370 | species_genes[species_genes.size - 1][key] = new_genes[key];
|
---|
| 371 | }
|
---|
[567] | 372 | }
|
---|
| 373 |
|
---|
[421] | 374 | // -------------------------------- foram begin -----------------------------------
|
---|
[380] | 375 |
|
---|
[479] | 376 | function setForamMeta(cr)
|
---|
[430] | 377 | {
|
---|
[479] | 378 | //percent of current energy
|
---|
[847] | 379 | cr.idleen = (ExpProperties.e_meta * cr.energy) * ExpProperties.secPerStep;
|
---|
[430] | 380 | }
|
---|
| 381 |
|
---|
| 382 | function lastChamberNum(cr)
|
---|
| 383 | {
|
---|
[567] | 384 | return cr.numparts;
|
---|
[430] | 385 | }
|
---|
| 386 |
|
---|
[479] | 387 | function getZoneRange(cr, zone_num)
|
---|
| 388 | {
|
---|
[847] | 389 | return ExpProperties.["zone" + zone_num + "_range"];
|
---|
[479] | 390 | }
|
---|
| 391 |
|
---|
[567] | 392 | function addReticulopodia(cr, radius)
|
---|
| 393 | {
|
---|
[847] | 394 | if (reticulopodiaExists(cr))
|
---|
| 395 | {
|
---|
| 396 | Populations[2].delete(cr.data->reticulopodiacreature);
|
---|
| 397 | }
|
---|
[1152] | 398 | radius = Math.max(radius, MIN_PART_SIZE);
|
---|
| 399 | var ret = Populations[2].add("//0s\nm:Vstyle=reticulopodia\np:sh=1,sx=" + MIN_PART_SIZE + ",sy=" + MIN_PART_SIZE + ",sz=" + MIN_PART_SIZE + "\n" +
|
---|
| 400 | "p:sh=3,sx=" + MIN_PART_SIZE + ",sy=" + radius + ",sz=" + radius + ",ry=1.57079633,vr=" + curColor + "\n" +
|
---|
| 401 | "j:0, 1, sh=1");
|
---|
[847] | 402 | cr.data->reticulopodiacreature = ret;
|
---|
| 403 | ret.getMechPart(0).orient.set(cr.getMechPart(0).orient);
|
---|
| 404 | ret.locationSetBboxLow(cr.bboxCenter.x - radius, cr.bboxCenter.y - radius, cr.bboxCenter.z - radius);
|
---|
[567] | 405 | }
|
---|
| 406 |
|
---|
[421] | 407 | function onForamsBorn(cr)
|
---|
| 408 | {
|
---|
[479] | 409 | setForamMeta(cr);
|
---|
[486] | 410 | if (ExpProperties.visualize == 1)
|
---|
[430] | 411 | {
|
---|
[567] | 412 | addReticulopodia(cr, curRadius);
|
---|
[583] | 413 | moveReticulopodia(cr);
|
---|
[430] | 414 | }
|
---|
[380] | 415 | }
|
---|
| 416 |
|
---|
[401] | 417 | function placeRandomlyNotColliding(cr)
|
---|
| 418 | {
|
---|
| 419 | var retry = 100; //try 100 times
|
---|
| 420 | while (retry--)
|
---|
| 421 | {
|
---|
| 422 | placeCreatureRandomly(cr, 0, 0);
|
---|
| 423 | if (!cr.boundingBoxCollisions(0))
|
---|
[588] | 424 | {
|
---|
[847] | 425 | cr.locationSetBboxLow(cr.bboxLow.x, cr.bboxLow.y, -cr.getPart(cr.numparts - 1).sx); //place slightly under the bottom surface ("z" value depends on the size of the last=largest chamber)
|
---|
[401] | 426 | return cr;
|
---|
[588] | 427 | }
|
---|
[401] | 428 | }
|
---|
| 429 |
|
---|
| 430 | Populations[0].delete(cr);
|
---|
| 431 | }
|
---|
| 432 |
|
---|
[567] | 433 | function reticulopodiaExists(cr)
|
---|
[444] | 434 | {
|
---|
| 435 | var has_ret = 0;
|
---|
| 436 |
|
---|
[908] | 437 | if (cr.data.hasKey("reticulopodiacreature"))
|
---|
[444] | 438 | {
|
---|
[476] | 439 | if (Populations[2].findUID(cr.data->reticulopodiacreature.uid) != null)
|
---|
[444] | 440 | {
|
---|
| 441 | has_ret = 1;
|
---|
| 442 | }
|
---|
| 443 | }
|
---|
| 444 |
|
---|
| 445 | return has_ret;
|
---|
| 446 | }
|
---|
| 447 |
|
---|
[567] | 448 | function visualization(cr)
|
---|
[380] | 449 | {
|
---|
[567] | 450 | return reticulopodiaExists(cr);
|
---|
| 451 | }
|
---|
| 452 |
|
---|
| 453 | function foramGrow(cr, chamber_num, lastchambergrowth)
|
---|
| 454 | {
|
---|
[847] | 455 | if ((chamber_num + 1) <= max_chamber_volume[cr.data->lifeparams->gen].size)
|
---|
[474] | 456 | {
|
---|
[579] | 457 | curColor = colors[cr.data->lifeparams->gen];
|
---|
[567] | 458 | var ploid = cr.data->lifeparams->gen;
|
---|
[847] | 459 | var geno = create_genotype(getPloidRadius(ploid), chamber_num + 1, colors[ploid], lastchambergrowth);
|
---|
[595] | 460 | var cr2 = createAndRotate(geno, 0, 0, 0);
|
---|
[422] | 461 |
|
---|
[595] | 462 | cr2.orient.set(cr.orient);
|
---|
[474] | 463 | cr2.energy0 = cr.energy;
|
---|
| 464 | cr2.energy = cr2.energy0;
|
---|
[422] | 465 |
|
---|
[554] | 466 | setGenotype({"cr" : cr2, "parent_genes" : cr.data->genes, "parent_lifeparams" : cr.data->lifeparams, "opt" : "growth", "energy0" : cr.energy0});
|
---|
[847] | 467 | cr2.locationSetBboxLow(cr.bboxLow.x, cr.bboxLow.y, cr.bboxLow.z);
|
---|
[479] | 468 | setForamMeta(cr2);
|
---|
[422] | 469 |
|
---|
[567] | 470 | if (reticulopodiaExists(cr))
|
---|
[474] | 471 | {
|
---|
[476] | 472 | Populations[2].delete(cr.data->reticulopodiacreature);
|
---|
[474] | 473 | }
|
---|
| 474 | Populations[0].delete(cr);
|
---|
[567] | 475 | return cr2;
|
---|
[430] | 476 | }
|
---|
[567] | 477 | return cr;
|
---|
[380] | 478 | }
|
---|
| 479 |
|
---|
[583] | 480 | function visualizeChamberGrowth(cr, chamber_time)
|
---|
| 481 | {
|
---|
| 482 | var total_time = secToSimSteps(ExpProperties.chamberGrowthSec);
|
---|
[847] | 483 | var ret_unit = total_time / chamber_vis_denominator;
|
---|
| 484 | var chamber_unit = total_time - ret_unit;
|
---|
[583] | 485 |
|
---|
| 486 | if (chamber_time < ret_unit || chamber_time >= chamber_unit)
|
---|
| 487 | {
|
---|
[847] | 488 | var new_rad = Math.min(Math.max((chamber_time % ret_unit) / ret_unit * getZoneRange(cr, 1), 0.01), getZoneRange(cr, 1));
|
---|
[583] | 489 |
|
---|
| 490 | if(chamber_time < ret_unit)
|
---|
| 491 | {
|
---|
[847] | 492 | new_rad = getZoneRange(cr, 1) - new_rad;
|
---|
[583] | 493 | }
|
---|
| 494 |
|
---|
| 495 | curColor = colors[cr.data->lifeparams->gen];
|
---|
[847] | 496 | addReticulopodia(cr, new_rad);
|
---|
[583] | 497 |
|
---|
| 498 | if (chamber_time == 0)//checking for end of chamber growth process
|
---|
| 499 | {
|
---|
[847] | 500 | cr.data->lifeparams->chamber_growth = -1;
|
---|
[583] | 501 | }
|
---|
| 502 | }
|
---|
| 503 | else
|
---|
| 504 | {
|
---|
[847] | 505 | var new_rad = 1 - Math.min(Math.max((chamber_time - ret_unit) / chamber_unit, 0.01), 1);
|
---|
[583] | 506 | curRadius = cr.data->reticulopodiacreature.getPart(1).sy;
|
---|
[847] | 507 |
|
---|
[583] | 508 | if (chamber_time == ret_unit)
|
---|
| 509 | {
|
---|
| 510 | new_rad = 1;
|
---|
| 511 | }
|
---|
| 512 |
|
---|
[847] | 513 | var new_cr = foramGrow(cr, chamberNumFromEnergy(cr.data->lifeparams->max_energy_level, cr.data->lifeparams->gen) - 1, new_rad);
|
---|
| 514 | curRadius = getZoneRange(new_cr, 1);
|
---|
[583] | 515 | }
|
---|
| 516 | }
|
---|
| 517 |
|
---|
[435] | 518 | function stepToNearest(cr)
|
---|
[380] | 519 | {
|
---|
[638] | 520 | var p = XYZ.new(cr.bboxCenter.x, cr.bboxCenter.y, cr.bboxCenter.z);
|
---|
[847] | 521 | var n = cr.signals.receiveSet("nutrient", getZoneRange(cr, 2));
|
---|
[380] | 522 |
|
---|
[401] | 523 | //if signals are received find the source of the nearest
|
---|
[380] | 524 | if (n.size > 0)
|
---|
| 525 | {
|
---|
| 526 | var i;
|
---|
| 527 | var mp;
|
---|
| 528 | var distvec = XYZ.new(0, 0, 0);
|
---|
| 529 | var dist;
|
---|
[470] | 530 | var mindist = 100000000000.0;
|
---|
[380] | 531 | var mindistvec = null;
|
---|
[430] | 532 | var eating = 0;
|
---|
[380] | 533 |
|
---|
[401] | 534 | for (i = 0; i < n.size; i++)
|
---|
[380] | 535 | {
|
---|
[638] | 536 | mp = XYZ.new(n[i].value.bboxCenter.x, n[i].value.bboxCenter.y, n[i].value.bboxCenter.z);
|
---|
[595] | 537 | distvec.set(mp);
|
---|
| 538 | distvec.sub(p);
|
---|
[401] | 539 | dist = distvec.length;
|
---|
[847] | 540 | if (dist < getZoneRange(cr, 1))
|
---|
[380] | 541 | {
|
---|
[430] | 542 | if (n[i].value != null)
|
---|
| 543 | {
|
---|
| 544 | energyTransfer(cr, n[i].value);
|
---|
| 545 | eating = 1;
|
---|
| 546 | }
|
---|
| 547 | }
|
---|
[476] | 548 | else if (eating == 0 && cr.data->lifeparams->hibernated == 0 && dist < mindist)
|
---|
[430] | 549 | {
|
---|
[401] | 550 | mindist = dist;
|
---|
| 551 | mindistvec = distvec.clone();
|
---|
[380] | 552 | }
|
---|
| 553 | }
|
---|
| 554 |
|
---|
[476] | 555 | if (!eating && cr.data->lifeparams->hibernated == 0)
|
---|
[430] | 556 | {
|
---|
[588] | 557 | mindistvec.z = 0;
|
---|
[430] | 558 | mindistvec.normalize();
|
---|
[595] | 559 | mindistvec.scale(movePerStep);
|
---|
| 560 | cr.drive = mindistvec;
|
---|
[430] | 561 | moveEnergyDec(cr);
|
---|
| 562 | }
|
---|
| 563 |
|
---|
[422] | 564 | return 1;
|
---|
[380] | 565 | }
|
---|
[847] | 566 |
|
---|
[422] | 567 | else
|
---|
[474] | 568 | {
|
---|
[422] | 569 | return 0;
|
---|
[474] | 570 | }
|
---|
[422] | 571 | }
|
---|
[401] | 572 |
|
---|
[422] | 573 | function moveEnergyDec(cr)
|
---|
| 574 | {
|
---|
[476] | 575 | if (cr.data->lifeparams->hibernated == 0)
|
---|
[422] | 576 | {
|
---|
[479] | 577 | //percent of maximal energy
|
---|
[847] | 578 | cr.energy -= (ExpProperties.energy_move * cr.data->lifeparams->max_energy_level) * ExpProperties.secPerStep;
|
---|
[422] | 579 | }
|
---|
[421] | 580 | }
|
---|
[380] | 581 |
|
---|
[584] | 582 | function fence(center, zone)
|
---|
[487] | 583 | {
|
---|
[847] | 584 | return Math.min(Math.max(0 + zone, center), World.wrldsiz - zone); //add and subtract zone from the world size to prevent reticulopodia from crossing the fence
|
---|
[487] | 585 | }
|
---|
| 586 |
|
---|
[422] | 587 | function foramMove(cr)
|
---|
[421] | 588 | {
|
---|
[430] | 589 | //are there any nutrients in zone 1 or 2?
|
---|
[401] | 590 | {
|
---|
[435] | 591 | var moved = stepToNearest(cr); //TODO weighted sum of distance and energy
|
---|
[847] | 592 | if (moved == 1)
|
---|
| 593 | {
|
---|
[502] | 594 | moveReticulopodia(cr);
|
---|
[422] | 595 | return;
|
---|
| 596 | }
|
---|
[401] | 597 | }
|
---|
| 598 |
|
---|
[847] | 599 | //Prevents forams from crossing the world border. In the case of touching the border with the reticulopodia direction of the movement should be changed.
|
---|
[584] | 600 | var change_direction = 0;
|
---|
[638] | 601 | var new_x = fence(cr.bboxCenter.x, getZoneRange(cr, 1));
|
---|
| 602 | var new_y = fence(cr.bboxCenter.y, getZoneRange(cr, 1));
|
---|
[584] | 603 |
|
---|
[638] | 604 | if ((new_x != cr.bboxCenter.x) || (new_y != cr.bboxCenter.y) || (cr.data->lifeparams->dir_counter >= int(secToSimSteps(ExpProperties.dir_change_sec))))
|
---|
[584] | 605 | {
|
---|
| 606 | change_direction = 1;
|
---|
[847] | 607 | cr.locationSetBboxLow(new_x - cr.bboxSize.x / 2, new_y - cr.bboxSize.y / 2, -cr.getPart(cr.numparts - 1).sx); //place slightly under the bottom surface ("z" value depends on the size of the last=largest chamber)
|
---|
[584] | 608 | }
|
---|
| 609 |
|
---|
[422] | 610 | //no nutrients in zone 2
|
---|
[847] | 611 | if (getGene(cr, "hibernation", 0) == 1)
|
---|
[401] | 612 | {
|
---|
[430] | 613 | reverseHib(cr);
|
---|
[847] | 614 | cr.drive = XYZ.new(0, 0, 0);
|
---|
[380] | 615 | }
|
---|
[422] | 616 | //random move
|
---|
[554] | 617 | else if (change_direction == 1)
|
---|
[380] | 618 | {
|
---|
[476] | 619 | cr.data->lifeparams->dir = randomDir();
|
---|
[552] | 620 | cr.data->lifeparams->dir_counter = 0;
|
---|
[595] | 621 | cr.drive = cr.data->lifeparams->dir;
|
---|
[422] | 622 | moveEnergyDec(cr);
|
---|
| 623 | }
|
---|
[474] | 624 | else
|
---|
| 625 | {
|
---|
[595] | 626 | cr.drive = cr.data->lifeparams->dir;
|
---|
[474] | 627 | }
|
---|
[502] | 628 | moveReticulopodia(cr);
|
---|
[422] | 629 | }
|
---|
[401] | 630 |
|
---|
[502] | 631 | function moveReticulopodia(cr)
|
---|
| 632 | {
|
---|
| 633 | if (visualization(cr))
|
---|
| 634 | {
|
---|
[847] | 635 | cr.data->reticulopodiacreature.locationSetBboxLow(cr.bboxCenter.x - getZoneRange(cr, 1), cr.bboxCenter.y - getZoneRange(cr, 1), cr.bboxCenter.z - getZoneRange(cr, 1));
|
---|
[595] | 636 | cr.data->reticulopodiacreature.drive = cr.drive;
|
---|
[502] | 637 | }
|
---|
| 638 | }
|
---|
| 639 |
|
---|
[474] | 640 | function randomDir()
|
---|
| 641 | {
|
---|
[847] | 642 | var dir = (Math.rndUni(-ExpProperties.zone2_range, ExpProperties.zone2_range), Math.rndUni(-ExpProperties.zone2_range, ExpProperties.zone2_range), 0);
|
---|
[474] | 643 | dir.normalize();
|
---|
[847] | 644 | dir.scale(-1 * movePerStep);
|
---|
[474] | 645 | return dir;
|
---|
| 646 | }
|
---|
| 647 |
|
---|
[430] | 648 | function energyTransfer(cr1, cr2)
|
---|
[422] | 649 | {
|
---|
[847] | 650 | cr1.drive = XYZ.new(0, 0, 0);
|
---|
| 651 | var e = ExpProperties.feedtrans * cr1.energy * ExpProperties.secPerStep; //TODO efficiency dependent on age
|
---|
[502] | 652 | //Simulator.print("transferring "+e +"("+e*ExpProperties.ingestion+")"+" to "+cr1.name +" ("+ cr1.energy+") " +" from "+cr2.uid+" ("+cr2.energy+") "+ e/ExpProperties.secPerStep+ " per sec");
|
---|
[510] | 653 | var transferred = cr2.transferEnergyTo(cr1, e);
|
---|
[847] | 654 | cr1.energy -= transferred * (1 - ExpProperties.ingestion);
|
---|
[476] | 655 | if (cr1.data->lifeparams->hibernated == 1)
|
---|
[422] | 656 | {
|
---|
[430] | 657 | reverseHib(cr1);
|
---|
[422] | 658 | }
|
---|
| 659 | }
|
---|
[401] | 660 |
|
---|
[430] | 661 | function reverseHib(cr)
|
---|
| 662 | {
|
---|
[476] | 663 | if (cr.data->lifeparams->hibernated == 1)
|
---|
[430] | 664 | {
|
---|
[479] | 665 | setForamMeta(cr); //unhibernate
|
---|
[847] | 666 | }
|
---|
[430] | 667 | else
|
---|
| 668 | {
|
---|
[847] | 669 | cr.idleen = (ExpProperties.energy_hib * cr.energy) * ExpProperties.secPerStep; //hibernate
|
---|
[430] | 670 | }
|
---|
[476] | 671 | cr.data->lifeparams->hibernated = 1 - cr.data->lifeparams->hibernated;
|
---|
[430] | 672 | }
|
---|
| 673 |
|
---|
[422] | 674 | function onForamsStep(cr)
|
---|
| 675 | {
|
---|
[479] | 676 | //checking for gametogenesis process
|
---|
| 677 | if (cr.data->lifeparams->division_time > 0)
|
---|
[444] | 678 | {
|
---|
[847] | 679 | cr.data->lifeparams->division_time = Math.max(cr.data->lifeparams->division_time - 1, 0);
|
---|
[444] | 680 | }
|
---|
[479] | 681 | //checking for end of gametogenesis
|
---|
| 682 | else if (cr.data->lifeparams->division_time == 0)
|
---|
[422] | 683 | {
|
---|
[479] | 684 | //waiting for gamets fusion
|
---|
[422] | 685 | }
|
---|
[479] | 686 | //checking for chamber growth process
|
---|
| 687 | else if (cr.data->lifeparams->chamber_growth > 0)
|
---|
| 688 | {
|
---|
[847] | 689 | var chamber_time = Math.max(cr.data->lifeparams->chamber_growth - 1, 0);
|
---|
[567] | 690 | cr.data->lifeparams->chamber_growth = chamber_time;
|
---|
[504] | 691 | cr.energy -= ExpProperties.chamberCostPerSec * cr.energy * ExpProperties.secPerStep;
|
---|
[422] | 692 |
|
---|
[567] | 693 | if (visualization(cr))
|
---|
| 694 | {
|
---|
[583] | 695 | visualizeChamberGrowth(cr, chamber_time);
|
---|
[567] | 696 | }
|
---|
[479] | 697 | }
|
---|
[583] | 698 | //checking for end of the chamber growth process
|
---|
[847] | 699 | else if (cr.data->lifeparams->chamber_growth == 0 && visualization(cr) == 0)
|
---|
| 700 | {
|
---|
| 701 | foramGrow(cr, lastChamberNum(cr), 1);
|
---|
[479] | 702 | cr.data->lifeparams->chamber_growth = -1;
|
---|
| 703 | //Simulator.print("chamber "+ (lastChamberNum(cr) + 1) +" complete");
|
---|
[430] | 704 | }
|
---|
[479] | 705 | else
|
---|
[422] | 706 | {
|
---|
[479] | 707 | //update of metabolism rate
|
---|
| 708 | if (cr.data->lifeparams->hibernated == 0)
|
---|
[401] | 709 | {
|
---|
[479] | 710 | setForamMeta(cr);
|
---|
| 711 | }
|
---|
| 712 |
|
---|
| 713 | if (deathConditions(cr) == 1)
|
---|
| 714 | {
|
---|
[493] | 715 | if (ExpProperties.logging == 1)
|
---|
| 716 | {
|
---|
[847] | 717 | log(createLogVector(cr, cr.data->lifeparams->max_energy_level), ExpProperties.logPref + "fossil_log.txt");
|
---|
| 718 | log(createLogVector(cr, cr.lifespan), ExpProperties.logPref + "lifespan_log.txt");
|
---|
| 719 | }
|
---|
[479] | 720 | Populations[0].kill(cr);
|
---|
| 721 | return;
|
---|
| 722 | }
|
---|
| 723 |
|
---|
[552] | 724 | //update direction change counter
|
---|
| 725 | cr.data->lifeparams->dir_counter += 1;
|
---|
| 726 |
|
---|
[479] | 727 | foramMove(cr);
|
---|
| 728 |
|
---|
| 729 | var repro = foramReproduce(cr);
|
---|
| 730 | if (repro == 1)
|
---|
| 731 | {
|
---|
| 732 | return;
|
---|
| 733 | }
|
---|
| 734 |
|
---|
| 735 | cr.data->lifeparams->max_energy_level = Math.max(cr.energy, cr.data->lifeparams->max_energy_level);
|
---|
| 736 |
|
---|
| 737 | //cheking conditions of chamber growth process start
|
---|
[567] | 738 | if (lastChamberNum(cr) < max_chamber_volume[cr.data->lifeparams->gen].size)
|
---|
[479] | 739 | {
|
---|
[847] | 740 | if ((cr.data->lifeparams->max_energy_level >= energyFromVolume(max_chamber_volume[cr.data->lifeparams->gen][lastChamberNum(cr) - 1], 0)))
|
---|
[479] | 741 | {
|
---|
[554] | 742 | cr.data->lifeparams->chamber_growth = int(secToSimSteps(ExpProperties.chamberGrowthSec));
|
---|
[847] | 743 | }
|
---|
[479] | 744 | }
|
---|
[847] | 745 | }
|
---|
[380] | 746 | }
|
---|
| 747 |
|
---|
[422] | 748 | function deathConditions(cr)
|
---|
| 749 | {
|
---|
[847] | 750 | if ((cr.energy <= getProperty(cr.data->lifeparams->gen, "e_death_level")*cr.data->lifeparams->max_energy_level) || (Math.rnd01 < ExpProperties.hunted_prob))
|
---|
[479] | 751 | {
|
---|
[422] | 752 | return 1;
|
---|
[479] | 753 | }
|
---|
[422] | 754 | else
|
---|
| 755 | return 0;
|
---|
| 756 | }
|
---|
| 757 |
|
---|
[421] | 758 | function onForamsDied(cr)
|
---|
[380] | 759 | {
|
---|
[444] | 760 | if (visualization(cr))
|
---|
[430] | 761 | {
|
---|
[476] | 762 | Populations[2].delete(cr.data->reticulopodiacreature);
|
---|
[430] | 763 | }
|
---|
[380] | 764 | //fossilization
|
---|
| 765 | var geno = GenePools[0].add(cr.genotype);
|
---|
[476] | 766 | geno.data->genes = cr.data->genes;
|
---|
| 767 | geno.data->lifeparams = cr.data->lifeparams;
|
---|
[486] | 768 | if (ExpProperties.logging == 1) Simulator.print("\"" + cr.name + "\" died...");
|
---|
[380] | 769 | ExpState.totaltestedcr++;
|
---|
| 770 | }
|
---|
| 771 |
|
---|
[421] | 772 | // --------------------------------foram end -------------------------------------
|
---|
[380] | 773 |
|
---|
[421] | 774 | // -------------------------------- nutrient begin --------------------------------
|
---|
[380] | 775 |
|
---|
[479] | 776 | function createNutrientGenotype(nutrientradius)
|
---|
[422] | 777 | {
|
---|
[1074] | 778 | return "//0s\nm:Vstyle=nutrient\np:sh=3,sx=" + nutrientradius + ",sy=" + nutrientradius + ",sz=" + nutrientradius + ",ry=1.57,vr=0.0,1.0,0.0";
|
---|
[422] | 779 | }
|
---|
| 780 |
|
---|
[421] | 781 | function onNutrientsStep(cr)
|
---|
[380] | 782 | {
|
---|
[638] | 783 | cr.locationSetBboxLow(cr.bboxLow.x % World.wrldsiz, cr.bboxLow.y % World.wrldsiz, 0.5);
|
---|
[380] | 784 | }
|
---|
| 785 |
|
---|
[421] | 786 | function addNutrient()
|
---|
[380] | 787 | {
|
---|
[486] | 788 | var cr = Populations[1].add(createNutrientGenotype(ExpProperties.nutrientradius));
|
---|
[380] | 789 |
|
---|
[421] | 790 | cr.name = "Nutrients";
|
---|
[380] | 791 | cr.idleen = 0;
|
---|
[486] | 792 | cr.energy0 = ExpProperties.energy_nut;
|
---|
[416] | 793 | cr.energy = cr.energy0;
|
---|
[421] | 794 | cr.signals.add("nutrient");
|
---|
[380] | 795 |
|
---|
[430] | 796 | cr.signals[0].value = cr;
|
---|
[380] | 797 |
|
---|
[422] | 798 | placeCreatureRandomly(cr, 0, 0);
|
---|
[486] | 799 | if (ExpProperties.visualize == 1)
|
---|
[444] | 800 | {
|
---|
[847] | 801 | var nutsize = ExpProperties.nutrientradius * 10;
|
---|
[1074] | 802 | var nut = Populations[2].add("//0s\nm:Vstyle=nutrient_visual\np:sh=2,sx=" + nutsize + ",sy=" + nutsize + ",sz=" + nutsize + ",ry=1.5,vr=0.0,1.0,0.0");
|
---|
[476] | 803 | cr.data->reticulopodiacreature = nut;
|
---|
[847] | 804 | nut.locationSetBboxLow( cr.bboxLow.x + cr.bboxSize.x / 2 - nut.bboxSize.x / 2, cr.bboxLow.y + cr.bboxSize.y / 2 - nut.bboxSize.y / 2, -nutsize);
|
---|
[444] | 805 | }
|
---|
[380] | 806 | }
|
---|
| 807 |
|
---|
[444] | 808 | function onNutrientsDied(cr)
|
---|
| 809 | {
|
---|
| 810 | if (visualization(cr))
|
---|
| 811 | {
|
---|
[476] | 812 | Populations[2].delete(cr.data->reticulopodiacreature);
|
---|
[444] | 813 | }
|
---|
| 814 | }
|
---|
| 815 |
|
---|
[592] | 816 | function getNumberCounter(counter, increase, unitsize) //increase counter and then deduct and return an integer (=discrete) number of "full" units
|
---|
[590] | 817 | {
|
---|
| 818 | counter += increase;
|
---|
[847] | 819 | var unitcount = int(counter / unitsize);
|
---|
| 820 | counter -= unitcount * unitsize;
|
---|
[592] | 821 | return {"counter" : counter, "number" : unitcount};
|
---|
[590] | 822 | }
|
---|
| 823 |
|
---|
[422] | 824 | function nutrientGrowth()
|
---|
[380] | 825 | {
|
---|
[590] | 826 | if (ExpProperties.foodfluxChange > 0)
|
---|
[481] | 827 | {
|
---|
[847] | 828 | changePeriod += 1;
|
---|
| 829 | if (phase == "low" && changePeriod >= secToSimSteps(23328000)) //9 months
|
---|
| 830 | {
|
---|
| 831 | ExpProperties.foodflux = ExpProperties.foodflux / ExpProperties.foodfluxChange;
|
---|
| 832 | phase = "high";
|
---|
| 833 | changePeriod = 0;
|
---|
| 834 | }
|
---|
| 835 |
|
---|
| 836 | else if (phase == "high" && changePeriod >= secToSimSteps(7776000)) //3 months
|
---|
| 837 | {
|
---|
| 838 | ExpProperties.foodflux = ExpProperties.foodflux * ExpProperties.foodfluxChange;
|
---|
| 839 | phase = "low";
|
---|
| 840 | changePeriod = 0;
|
---|
| 841 | }
|
---|
[481] | 842 | }
|
---|
[422] | 843 |
|
---|
[847] | 844 | var nutrientNum = getNumberCounter(nutrient_num_counter, ExpProperties.foodflux * wrldsizSquareMeters * ExpProperties.secPerStep, ExpProperties.energy_nut * 0.000000000001);
|
---|
[493] | 845 |
|
---|
[590] | 846 | nutrient_num_counter = nutrientNum["counter"];
|
---|
| 847 |
|
---|
| 848 | for (var i = 0; i < nutrientNum["number"]; i++)
|
---|
[847] | 849 | {
|
---|
[590] | 850 | addNutrient();
|
---|
[380] | 851 | }
|
---|
[493] | 852 |
|
---|
[590] | 853 | if (ExpProperties.logging == 1 && nutrientNum["number"] > 0)
|
---|
| 854 | {
|
---|
[847] | 855 | log([nutrientNum["number"]], ExpProperties.logPref + "nutrients_log.txt");
|
---|
[590] | 856 | }
|
---|
| 857 |
|
---|
[380] | 858 | }
|
---|
| 859 |
|
---|
[421] | 860 | // -------------------------------- nutrient end --------------------------------
|
---|
[380] | 861 |
|
---|
[422] | 862 | // -------------------------------- step begin --------------------------------
|
---|
[380] | 863 |
|
---|
[422] | 864 | function onStep()
|
---|
| 865 | {
|
---|
[432] | 866 |
|
---|
| 867 | nutrientGrowth();
|
---|
[486] | 868 | if (ExpProperties.logging == 1)
|
---|
[422] | 869 | {
|
---|
| 870 | createStatistics();
|
---|
| 871 | }
|
---|
| 872 |
|
---|
| 873 | //reproduction --------------------------------------------
|
---|
| 874 | reprocounter += 1;
|
---|
[554] | 875 | if (reprocounter > secToSimSteps(ExpProperties.reproTimeSec))
|
---|
[422] | 876 | {
|
---|
| 877 | reprocounter = 0;
|
---|
[567] | 878 | for (var s = 0; s < species_genes.size; s++)
|
---|
| 879 | {
|
---|
| 880 | reproduce_parents(s);
|
---|
| 881 | }
|
---|
[847] | 882 |
|
---|
[422] | 883 | }
|
---|
| 884 |
|
---|
| 885 | //check for extinction -----------------------------------------------
|
---|
| 886 | if (Populations[0].size == 0)
|
---|
| 887 | {
|
---|
[486] | 888 | if (ExpProperties.autorestart)
|
---|
[422] | 889 | {
|
---|
| 890 | Simulator.print("no more creatures, restarting...");
|
---|
| 891 | onExpInit();
|
---|
| 892 | }
|
---|
| 893 | else
|
---|
| 894 | {
|
---|
| 895 | Simulator.print("no more creatures, stopped.");
|
---|
| 896 | Simulator.stop();
|
---|
| 897 | }
|
---|
| 898 | }
|
---|
[486] | 899 | if (ExpProperties.maxSteps > 0)
|
---|
[432] | 900 | {
|
---|
[486] | 901 | if (Simulator.stepNumber >= ExpProperties.maxSteps)
|
---|
[432] | 902 | Simulator.stop();
|
---|
| 903 | }
|
---|
[422] | 904 | }
|
---|
| 905 |
|
---|
| 906 | function createStatistics()
|
---|
[847] | 907 | {
|
---|
[487] | 908 | var number = [];
|
---|
| 909 | var e_inc = [];
|
---|
[422] | 910 | var e_nut = 0.0;
|
---|
| 911 |
|
---|
[487] | 912 | for (var s = 0; s < species_genes.size; s++)
|
---|
| 913 | {
|
---|
[847] | 914 | number.add([0, 0]); // [haplo][diplo]
|
---|
| 915 | e_inc.add([0, 0]);
|
---|
[487] | 916 | }
|
---|
| 917 |
|
---|
[422] | 918 | for (var i = 0; i < Populations[0].size; i++)
|
---|
| 919 | {
|
---|
| 920 | var cr = Populations[0].get(i);
|
---|
[476] | 921 | var gen = cr.data->lifeparams->gen;
|
---|
| 922 | var species = cr.data->lifeparams->species;
|
---|
[430] | 923 |
|
---|
[847] | 924 | number[species][gen] = number[species][gen] + 1;
|
---|
[430] | 925 | e_inc[species][gen] = e_inc[species][gen] + cr.energy;
|
---|
[422] | 926 | }
|
---|
| 927 |
|
---|
| 928 | for (var i = 0; i < Populations[1].size; i++)
|
---|
| 929 | {
|
---|
| 930 | var cr = Populations[1].get(i);
|
---|
| 931 | e_nut += cr.energy;
|
---|
| 932 | }
|
---|
| 933 |
|
---|
[487] | 934 | var log_numbers = [];
|
---|
| 935 | var log_energies = [];
|
---|
[422] | 936 |
|
---|
[487] | 937 | for (var s = 0; s < species_genes.size; s++)
|
---|
| 938 | {
|
---|
| 939 | for (var p = 0; p < 2; p++)
|
---|
| 940 | {
|
---|
| 941 | log_numbers.add(number[s][p]);
|
---|
| 942 | log_energies.add(e_inc[s][p]);
|
---|
| 943 | }
|
---|
| 944 | }
|
---|
[847] | 945 |
|
---|
[487] | 946 | log_numbers.add(Populations[1].size);
|
---|
| 947 | log_energies.add(e_nut);
|
---|
| 948 |
|
---|
[847] | 949 | log(log_numbers, ExpProperties.logPref + "forams_log.txt");
|
---|
| 950 | log(log_energies, ExpProperties.logPref + "energies_log.txt");
|
---|
[422] | 951 | }
|
---|
| 952 |
|
---|
[380] | 953 | function log(tolog, fname)
|
---|
| 954 | {
|
---|
[847] | 955 | var f = File.appendDirect(fname, "forams data");
|
---|
[380] | 956 | f.writeString("" + Simulator.stepNumber);
|
---|
[401] | 957 | for (var i = 0; i < tolog.size; i++)
|
---|
[380] | 958 | {
|
---|
| 959 | f.writeString(";" + tolog[i]);
|
---|
| 960 | }
|
---|
| 961 | f.writeString("\n");
|
---|
| 962 | f.close();
|
---|
| 963 | }
|
---|
| 964 |
|
---|
[567] | 965 | function createLogVector(cr, value)
|
---|
| 966 | {
|
---|
| 967 | var vec = Vector.new();
|
---|
| 968 | for (var i = 0; i < species_genes.size; i++)
|
---|
| 969 | {
|
---|
| 970 | for (var j = 0; j < 2; j++)
|
---|
| 971 | {
|
---|
| 972 | vec.add(0);
|
---|
| 973 | }
|
---|
| 974 | if (cr.data->lifeparams->species == i)
|
---|
| 975 | {
|
---|
[847] | 976 | vec[i * 2 + cr.data->lifeparams->gen] = value;
|
---|
[567] | 977 | }
|
---|
| 978 | }
|
---|
| 979 | return vec;
|
---|
| 980 | }
|
---|
| 981 |
|
---|
| 982 |
|
---|
[422] | 983 | // -------------------------------- step end --------------------------------
|
---|
[479] | 984 | //TODO default params values in frams instead of microns/seconds
|
---|
[380] | 985 |
|
---|
[401] | 986 | @include "standard_events.inc"
|
---|
[380] | 987 |
|
---|
[401] | 988 | ~
|
---|
[380] | 989 |
|
---|
[486] | 990 | property:
|
---|
[444] | 991 | id:visualize
|
---|
| 992 | name:Show reticulopodia and nutrients
|
---|
[430] | 993 | type:d 0 1 0
|
---|
[554] | 994 | group:
|
---|
[430] | 995 |
|
---|
[486] | 996 | property:
|
---|
[434] | 997 | id:maxSteps
|
---|
[554] | 998 | name:Maximum number of steps
|
---|
[552] | 999 | type:d 0 10000000 0
|
---|
[554] | 1000 | group:
|
---|
[432] | 1001 |
|
---|
[486] | 1002 | property:
|
---|
[567] | 1003 | id:scalingFactor
|
---|
| 1004 | name:Scaling factor for micrometers
|
---|
| 1005 | type:f 0 -1 0.01
|
---|
| 1006 | group:
|
---|
| 1007 |
|
---|
| 1008 | property:
|
---|
[554] | 1009 | id:secPerStep
|
---|
| 1010 | name:Seconds per simulation step
|
---|
[568] | 1011 | help:~
|
---|
[570] | 1012 | Number of seconds of foraminifera time per simulation step.
|
---|
| 1013 | Lower values mean smoother animation.~
|
---|
[554] | 1014 | type:f 1 480 300
|
---|
| 1015 | flags: 16
|
---|
| 1016 | group:
|
---|
| 1017 |
|
---|
| 1018 | property:
|
---|
[474] | 1019 | id:foramSpeedMmPerMin
|
---|
| 1020 | name:Speed of foraminfera in mm/min
|
---|
[554] | 1021 | type:f 0.01 0.1 0.05
|
---|
[474] | 1022 | flags: 16
|
---|
| 1023 | group:Foraminifera
|
---|
| 1024 |
|
---|
[486] | 1025 | property:
|
---|
[554] | 1026 | id:dir_change_sec
|
---|
| 1027 | name:Number of seconds before direction change
|
---|
| 1028 | type:d 300 300000 6000
|
---|
[479] | 1029 | group:Foraminifera
|
---|
| 1030 |
|
---|
[486] | 1031 | property:
|
---|
[554] | 1032 | id:foramPop
|
---|
| 1033 | name:Initial forams population size
|
---|
| 1034 | type:d 1 1000 20
|
---|
[552] | 1035 | group:Foraminifera
|
---|
| 1036 |
|
---|
| 1037 | property:
|
---|
[554] | 1038 | id:gametoPeriodSec
|
---|
[479] | 1039 | name:Time of gametogenesis
|
---|
[554] | 1040 | type:f 300 300000 21600
|
---|
| 1041 | group:Reproduction
|
---|
[479] | 1042 |
|
---|
[486] | 1043 | property:
|
---|
[554] | 1044 | id:gametSuccessRate
|
---|
| 1045 | name:Ratio of successful gamets
|
---|
| 1046 | type:f 0.0001 0.01 0.001
|
---|
| 1047 | group:Reproduction
|
---|
[479] | 1048 |
|
---|
[486] | 1049 | property:
|
---|
[554] | 1050 | id:divisionCost
|
---|
| 1051 | name:Cost of division in pG
|
---|
| 1052 | type:f 15 25 20
|
---|
| 1053 | group:Reproduction
|
---|
[474] | 1054 |
|
---|
[486] | 1055 | property:
|
---|
[554] | 1056 | id:min_repro_energ_haplo
|
---|
[567] | 1057 | name:Min reproduction energy of haploid in pg
|
---|
| 1058 | type:f 0 -1 350000
|
---|
[554] | 1059 | group:Energy
|
---|
[380] | 1060 |
|
---|
[486] | 1061 | property:
|
---|
[554] | 1062 | id:min_repro_energ_diplo
|
---|
[567] | 1063 | name:Min reproduction energy of diploid in pg
|
---|
| 1064 | type:f 0 -1 600000
|
---|
[554] | 1065 | group:Energy
|
---|
[479] | 1066 |
|
---|
[486] | 1067 | property:
|
---|
[554] | 1068 | id:repro_prob
|
---|
| 1069 | name:Probability of reproduction
|
---|
| 1070 | type:f 0 1 0.8
|
---|
| 1071 | group:Reproduction
|
---|
[380] | 1072 |
|
---|
[486] | 1073 | property:
|
---|
[554] | 1074 | id:energies0_haplo
|
---|
| 1075 | name:Energy of offspring from diploid forams
|
---|
| 1076 | type:f 0 -1 20
|
---|
| 1077 | group:Energy
|
---|
[479] | 1078 |
|
---|
[486] | 1079 | property:
|
---|
[554] | 1080 | id:energies0_diplo
|
---|
| 1081 | name:Energy of offspring from diploid forams
|
---|
| 1082 | type:f 0 -1 1.25
|
---|
| 1083 | group:Energy
|
---|
| 1084 |
|
---|
| 1085 | property:
|
---|
[567] | 1086 | id:max_chamber_num_haplo
|
---|
| 1087 | name:Maximum number of haploid chambers
|
---|
| 1088 | type:f 1 50 35
|
---|
| 1089 | group:Energy
|
---|
| 1090 |
|
---|
| 1091 | property:
|
---|
| 1092 | id:max_chamber_num_diplo
|
---|
| 1093 | name:Maximum number of diploid chambers
|
---|
| 1094 | type:f 1 50 35
|
---|
| 1095 | group:Energy
|
---|
| 1096 |
|
---|
| 1097 | property:
|
---|
[554] | 1098 | id:crossprob
|
---|
| 1099 | name:Crossover probability
|
---|
| 1100 | type:f 0 1 0
|
---|
| 1101 | group:Reproduction
|
---|
| 1102 |
|
---|
| 1103 | property:
|
---|
| 1104 | id:mutationprob
|
---|
| 1105 | name:Mutation probability
|
---|
| 1106 | type:f 0 1 0
|
---|
| 1107 | group:Reproduction
|
---|
| 1108 |
|
---|
| 1109 | property:
|
---|
| 1110 | id:reproTimeSec
|
---|
| 1111 | name:Time before reproduction
|
---|
| 1112 | type:d 0 10000 720
|
---|
| 1113 | group:Reproduction
|
---|
| 1114 |
|
---|
| 1115 | property:
|
---|
| 1116 | id:chamberGrowthSec
|
---|
| 1117 | name:Time of the chamber growth in seconds
|
---|
[567] | 1118 | type:f 720 43200 43200
|
---|
[479] | 1119 | group:Foraminifera
|
---|
| 1120 |
|
---|
[486] | 1121 | property:
|
---|
[422] | 1122 | id:chamber_proculus_haplo
|
---|
[423] | 1123 | name:Size of proculus
|
---|
[422] | 1124 | type:f
|
---|
[421] | 1125 | group:Foraminifera
|
---|
[380] | 1126 |
|
---|
[486] | 1127 | property:
|
---|
[422] | 1128 | id:chamber_proculus_diplo
|
---|
[423] | 1129 | name:Size of proculus
|
---|
[422] | 1130 | type:f
|
---|
[380] | 1131 | group:Foraminifera
|
---|
| 1132 |
|
---|
[486] | 1133 | property:
|
---|
[422] | 1134 | id:hunted_prob
|
---|
| 1135 | name:Probability of being hunted
|
---|
| 1136 | type:f 0 1 0
|
---|
[554] | 1137 | group:Foraminifera
|
---|
[380] | 1138 |
|
---|
[486] | 1139 | property:
|
---|
[557] | 1140 | id:zone1_range
|
---|
[556] | 1141 | name:Zone 1 range in frams units
|
---|
[554] | 1142 | type:f 0 200 10
|
---|
[422] | 1143 | group:Foraminifera
|
---|
[380] | 1144 |
|
---|
[486] | 1145 | property:
|
---|
[422] | 1146 | id:zone2_range
|
---|
[556] | 1147 | name:Zone 2 range in frams units
|
---|
[554] | 1148 | type:f 0 3000 30
|
---|
[421] | 1149 | group:Foraminifera
|
---|
[380] | 1150 |
|
---|
[486] | 1151 | property:
|
---|
[554] | 1152 | id:chamberCostPerSec
|
---|
| 1153 | name:Cost of growning chamber per second
|
---|
| 1154 | type:f 0 1 0.000001
|
---|
| 1155 | group:Energy
|
---|
[380] | 1156 |
|
---|
[486] | 1157 | property:
|
---|
[475] | 1158 | id:e_death_level_haplo
|
---|
| 1159 | name:Minimal level of energy to sustain life of haploid
|
---|
[554] | 1160 | type:f 0 1 0.5
|
---|
| 1161 | group:Energy
|
---|
[475] | 1162 |
|
---|
[486] | 1163 | property:
|
---|
[475] | 1164 | id:e_death_level_diplo
|
---|
| 1165 | name:Minimal level of energy to sustain life of diploid
|
---|
[554] | 1166 | type:f 0 1 0.5
|
---|
| 1167 | group:Energy
|
---|
[475] | 1168 |
|
---|
[486] | 1169 | property:
|
---|
[422] | 1170 | id:energy_hib
|
---|
| 1171 | name:Energy used for hibernation during one step
|
---|
[554] | 1172 | type:f 0 1 0.0000001
|
---|
| 1173 | group:Energy
|
---|
[422] | 1174 |
|
---|
[486] | 1175 | property:
|
---|
[422] | 1176 | id:energy_move
|
---|
| 1177 | name:Energy used for movement during one step
|
---|
[554] | 1178 | type:f 0 1 0.0000005
|
---|
| 1179 | group:Energy
|
---|
[422] | 1180 |
|
---|
[486] | 1181 | property:
|
---|
[380] | 1182 | id:e_meta
|
---|
| 1183 | name:Idle metabolism
|
---|
[554] | 1184 | type:f 0 1 0.0000005
|
---|
[380] | 1185 | group:Energy
|
---|
[556] | 1186 | help:Foraminifera consumes this proportion of its energy in one time step
|
---|
[380] | 1187 |
|
---|
[486] | 1188 | property:
|
---|
[554] | 1189 | id:ingestion
|
---|
| 1190 | name:Ingestion rate
|
---|
| 1191 | type:f 0 -1 0.25
|
---|
| 1192 | group:Energy
|
---|
| 1193 |
|
---|
| 1194 | property:
|
---|
[493] | 1195 | id:nutrient_pop
|
---|
[554] | 1196 | name:Nutrient population
|
---|
[474] | 1197 | type:f 0 1000000
|
---|
[380] | 1198 | group:Energy
|
---|
| 1199 | help:How fast energy is created in the world
|
---|
| 1200 |
|
---|
[486] | 1201 | property:
|
---|
[554] | 1202 | id:energy_nut
|
---|
| 1203 | name:Nutrient energy
|
---|
| 1204 | type:f 0 10000000
|
---|
[481] | 1205 | group:Energy
|
---|
| 1206 |
|
---|
[486] | 1207 | property:
|
---|
[554] | 1208 | id:nutrientradius
|
---|
| 1209 | name:Nutrient size
|
---|
| 1210 | type:f 0.001 0.9 0.1
|
---|
[479] | 1211 | group:Energy
|
---|
| 1212 |
|
---|
[486] | 1213 | property:
|
---|
[554] | 1214 | id:picoCarbonPerMikro
|
---|
[556] | 1215 | name:Picograms of carbon in cubic micrometer
|
---|
[554] | 1216 | type:f 0 -1 0.13
|
---|
[380] | 1217 | group:Energy
|
---|
| 1218 |
|
---|
[486] | 1219 | property:
|
---|
[380] | 1220 | id:feedtrans
|
---|
[479] | 1221 | name:Energy transfer per second
|
---|
[554] | 1222 | type:f 0 1 0.001
|
---|
[380] | 1223 | group:Energy
|
---|
[422] | 1224 |
|
---|
[486] | 1225 | property:
|
---|
[590] | 1226 | id:foodflux
|
---|
| 1227 | name:POM flux in grams per second per square meter
|
---|
| 1228 | type:f 0 1 0.0000000075631
|
---|
[422] | 1229 | group:Energy
|
---|
| 1230 |
|
---|
[486] | 1231 | property:
|
---|
[590] | 1232 | id:foodfluxChange
|
---|
[554] | 1233 | name:Set variable feed rate
|
---|
| 1234 | type:f 0 -1 0
|
---|
[421] | 1235 | group:Energy
|
---|
| 1236 |
|
---|
[486] | 1237 | property:
|
---|
[422] | 1238 | id:stress
|
---|
| 1239 | name:Environmental stress
|
---|
| 1240 | type:d 0 1 1
|
---|
[554] | 1241 | group:
|
---|
[422] | 1242 |
|
---|
[486] | 1243 | property:
|
---|
[422] | 1244 | id:repro_trigger
|
---|
| 1245 | name:Reproduction trigger
|
---|
| 1246 | type:d 0 1 1
|
---|
[554] | 1247 | group:Reproduction
|
---|
[422] | 1248 |
|
---|
[486] | 1249 | property:
|
---|
[422] | 1250 | id:creath
|
---|
| 1251 | name:Creation height
|
---|
[554] | 1252 | type:f -1 50 -0.99
|
---|
[422] | 1253 | help:~
|
---|
| 1254 | Vertical position (above the surface) where new Forams are revived.
|
---|
| 1255 | Negative values are only used in the water area:
|
---|
| 1256 | 0 = at the surface
|
---|
| 1257 | -0.5 = half depth
|
---|
| 1258 | -1 = just above the bottom~
|
---|
| 1259 |
|
---|
[554] | 1260 | property:
|
---|
| 1261 | id:autorestart
|
---|
| 1262 | name:Restart after extinction
|
---|
| 1263 | help:Restart automatically this experiment after the last creature has died?
|
---|
| 1264 | type:d 0 1 0
|
---|
| 1265 |
|
---|
[1100] | 1266 | property:
|
---|
| 1267 | id:logging
|
---|
| 1268 | name:Log statistics to file
|
---|
| 1269 | type:d 0 1 0
|
---|
| 1270 | group:
|
---|
| 1271 |
|
---|
| 1272 | property:
|
---|
| 1273 | id:logPref
|
---|
| 1274 | name:Log prefix
|
---|
| 1275 | type:s
|
---|
| 1276 |
|
---|
| 1277 | property:
|
---|
| 1278 | id:print_evol_progress
|
---|
| 1279 | name:Print evolution progress
|
---|
| 1280 | help:Print messages on evolution progress
|
---|
| 1281 | type:d 0 1 0
|
---|
| 1282 |
|
---|
[421] | 1283 | state:
|
---|
| 1284 | id:nutrient
|
---|
[428] | 1285 | name:Nutrient locations
|
---|
[421] | 1286 | help:vector of vectors [x,y,energy]
|
---|
| 1287 | type:x
|
---|
| 1288 | flags:32
|
---|
| 1289 |
|
---|
[380] | 1290 | state:
|
---|
| 1291 | id:notes
|
---|
| 1292 | name:Notes
|
---|
| 1293 | type:s 1
|
---|
| 1294 | help:~
|
---|
| 1295 | You can write anything here
|
---|
| 1296 | (it will be saved to the experiment file)~
|
---|
| 1297 |
|
---|
| 1298 | state:
|
---|
| 1299 | id:totaltestedcr
|
---|
[421] | 1300 | name:Evaluated Forams
|
---|
| 1301 | help:Total number of the Forams evaluated in the experiment
|
---|
[380] | 1302 | type:d
|
---|
| 1303 | flags:16
|
---|