ALMaSS Vole ODDox  1.1
The vole model description following ODdox protocol
vole_all.h
Go to the documentation of this file.
1 /*
2 *******************************************************************************************************
3 Copyright (c) 2011, Christopher John Topping, University of Aarhus
4 All rights reserved.
5 
6 Redistribution and use in source and binary forms, with or without modification, are permitted provided
7 that the following conditions are met:
8 
9 Redistributions of source code must retain the above copyright notice, this list of conditions and the
10 following disclaimer.
11 Redistributions in binary form must reproduce the above copyright notice, this list of conditions and
12 the following disclaimer in the documentation and/or other materials provided with the distribution.
13 
14 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
15 IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
16 FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS
17 BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
18 BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
19 BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
20 LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
21 SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
22 ********************************************************************************************************
23 */
39 //---------------------------------------------------------------------------
40 #ifndef Vole_allH
41 #define Vole_allH
42 
43 #include "GeneticMaterial.h"
44 
45 class MovementMap16;
46 
47 
48 //---------------------------------------------------------------------------
49 //---------------------------------------------------------------------------
50 
55 typedef enum
56 {
58  //Males
64  //Females
75 
76 
77 
78 typedef enum {
84 //------------------------------------------------------------------------------
85 
86 // Forward Declarations
87 
89 class Landscape;
90 class AlleleFreq1616;
93 class AlleleFreq;
94 class GeneticMaterial;
95 
96 //------------------------------------------------------------------------------
97 
98 typedef enum
99 {
105 } VoleObject;
106 
107 
113 {
114 public:
115  bool m_inAtrap;
116 };
117 
123 {
124  public:
125  int x;
126  int y;
127  int age;
128  double weight;
129  int xborn;
130  int yborn;
132  int ElemBorn;
133  int VegBorn;
135  int FatherId;
136  int MotherId;
140  //GeneticMaterial256_16 Genes256_16;
142  bool m_flag;
143  bool m_gflag;
144  bool m_dflag;
145  double misc_use; // used to pass a parameter e.g. for pesticide use
146 };
147 //------------------------------------------------------------------------------
152 class Vole_Base : public TAnimal
153 {
154 // Attributes
155 protected:
164  unsigned int m_MinTerrRange;
166  unsigned m_MotherId;
168  unsigned m_FatherId;
170  int m_Death;
174  bool m_Sex;
176  bool m_Mature;
178  int m_Age;
180  int m_XBorn; //*TD*
182  int m_YBorn; //*TD*
186  int m_ElemBorn; //*TD*
188  int m_VegBorn; //*TD*
192  double m_Weight;
194  bool m_fertile;
195 #ifdef __VoleStarvationDays
196 
197  int m_StarvationDays;
198 #endif
199  // No of young produced;
208  unsigned IDNo;
210  int SimH, SimW;
212  //GeneticMaterial256_16 MyGenes;
216  static unsigned int m_MaxMaleTerritorySize;
218  static unsigned int m_MaxFemaleTerritorySize;
220  static unsigned int m_MinMaleTerritorySize;
222  static unsigned int m_MinFemaleTerritorySize;
224  static double m_MinFVoleHabQual;
226  static double m_MinJMVoleHabQual;
228  static double m_MinMVoleHabQual;
233  // The values below were fitted by trial and error but await a detailed sensitivity analysis when spatial data is available
235  static double m_FHabQualThreshold3;
237  static double m_FHabQualThreshold2;
239  static double m_FHabQualThreshold1;
241  static double m_MHabQualThreshold3;
243  static double m_MHabQualThreshold2;
245  static double m_MHabQualThreshold1;
247  static bool m_BreedingSeason;
248 #ifdef __VoleStarvationDays
249 
251  static int m_MaxStarvationDays;
252 #endif
253 
254 #ifdef __VOLEPESTICIDEON
255 public:
256  double SupplyPesticideLoad() { return m_pesticideload; }
257  double SupplyBioDegradeRate() { return m_pesticideBioDegradeRate; }
258  void SetPesticideInfluenced1(bool a_bool) { m_pesticideInfluenced1 = a_bool; }
259  void SetPesticideInfluenced2(bool a_bool) { m_pesticideInfluenced2 = a_bool; }
260  bool GetPesticideInfluenced1() { return m_pesticideInfluenced1; }
261  bool GetPesticideInfluenced2() { return m_pesticideInfluenced2; }
262 protected:
263  bool m_pesticideInfluenced1;
264  bool m_pesticideInfluenced2;
265  double m_pesticideInfluenced3;
266  double m_pesticideload;
267  double m_pesticideBioDegradeRate;
268  void AddToPesticidLoad(double a_pestamount) { m_pesticideload+=a_pestamount; }
269  void BioDegradePesticide() { m_pesticideload *= m_pesticideBioDegradeRate; }
270  void ClearPesticidLoad() { m_pesticideload = 0.0; }
271  void SetBioDegradeRate(double a_rate) { m_pesticideBioDegradeRate = a_rate; }
272  virtual void PesticideIngestion( void );
273  virtual void ActOnPesticideDose( void );
274  virtual void ModelinkPesticide() { ; }
275  virtual void ModelinkPesticide21TWA(double /* a_dose */ ) { ; }
276  virtual void Vinclozolin(double /* a_dose */ ) { ; }
277  virtual void GeneralOrganophosphate(double /* a_dose */) { ; }
278  virtual void GeneralEndocrineDisruptor(double /* a_dose */) { ; }
279  virtual void GeneticDemoPesticide(double /* a_dose */){ ; }
280 #endif
281 #ifdef __VOLERODENTICIDEON
282  virtual void RodenticideIngestion(void);
283 #endif
284 public:
285 // Functions
286  Vole_Base(struct_Vole_Adult * p_aVoleStruct);
287  virtual ~Vole_Base();
288  virtual void Init(struct_Vole_Adult * p_aVoleStruct);
289  virtual void ReInit(struct_Vole_Adult * p_aVoleStruct);
290  virtual void BeginStep() {};
291  virtual void Step() {};
292  virtual void EndStep();
293  void st_Dying();
294 
296  void SetBreedingSeason( bool a_flag ) { m_BreedingSeason = a_flag; }
298  void SetWeight(double W) {m_Weight=W;}
300  void Setm_Mature() { m_Mature = true; }
302  void Set_BirthYear(int BirthYear) {m_BirthYear = BirthYear;}
303 
305  void Set_MotherId(unsigned MotherIdNo) {m_MotherId = MotherIdNo;}; // ***TD***
307  void Set_FatherId(unsigned FatherIdNo) {m_FatherId = FatherIdNo;}; // ***TD***
309  void Set_NoYoungTot (int a_NoOfYoung) {m_NoOfYoungTotal+=a_NoOfYoung;}; // ***TD***
311  void Set_XBorn (int a_Location_x) {m_XBorn = a_Location_x;}; // ***TD***
313  void Set_YBorn (int a_Location_y) {m_YBorn = a_Location_y;}; // ***TD***
315  void Set_ElemBorn (int a_Location_x, int a_Location_y) // ***TD***
316  {
317  TTypesOfLandscapeElement m_EBorn = m_OurLandscape->SupplyElementType(a_Location_x, a_Location_y);
319  }
321  void Set_VegBorn (int a_Location_x, int a_Location_y) // ***TD***
322  {
323  TTypesOfVegetation m_VBorn = (m_OurLandscape->SupplyVegType(a_Location_x, a_Location_y));
325  }
327  void Set_PolyRefBorn (int a_Location_x, int a_Location_y) {m_PolyRefBorn = (m_OurLandscape->SupplyPolyRef(a_Location_x, a_Location_y));}; // ***TD***
329  void Set_Age(int Age) {m_Age=Age;}
330 
332  virtual int WhatState() {return CurrentVState;}
336  bool SupplyTerritorial() {return m_Have_Territory;} // ***TD***
338  int SupplyFatherId() {return m_FatherId;}; // ***TD***
340  int SupplyMotherId() {return m_MotherId;}; // ***TD***
342  bool SupplySex() {return m_Sex;};
344  int SupplyBirthYear() {return m_BirthYear;}; // ***TD***
346  int SupplyTotNoYoung() {return m_NoOfYoungTotal;}; // ***TD***
348  int SupplyXBorn() {return m_XBorn;}; // ***TD***
350  int SupplyYBorn() {return m_YBorn;}; // ***TD***
352  int SupplyPolyRefBorn() {return m_PolyRefBorn;}; // ***TD***
354  int SupplyElemBorn() {return m_ElemBorn;}; // ***TD***
358  int SupplyVegBorn() {return m_VegBorn;}; // ***TD***
360  int SupplyTerrRange() {return m_TerrRange;}; // ***TD***
362  double SupplyWeight() {return m_Weight;};
364  int SupplyIDNo() {return IDNo;}; // ***TD***
366  bool SupplyMature() {return m_Mature;};
368  int SupplyDeathCause() {return m_Death;}; // ***TD***
370  unsigned SupplyAge() {return m_Age;};
372  unsigned SupplyX() {return m_Location_x;};
374  unsigned SupplyY() {return m_Location_y;};
376  bool SupplyInTrap() { return m_intrappos.m_inAtrap; }
380  void SetFree() { m_intrappos.m_inAtrap = false; }
386  int SupplyAllele(int locus, int allele) { return m_MyGenes.GetAllele(locus,allele); }
387  uint32 SupplyMyAllele(int i, int j)
388  {return m_MyGenes.GetAllele(i, j);} //*TD
403 
404  virtual void OnKilled() {};
405  virtual bool MortalityTest();
409  void CopyMyself( VoleObject a_vole );
414  void SetFertile(bool f) {
418  m_fertile=f;
419  }
424  bool GetFertile() {
428  return m_fertile;
429  }
430 protected:
431  double CalculateCarryingCapacity( int x, int y, int a_ddep );
432  //double CalculateCarryingCapacity(int x,int y,int &p_stand_x,int &p_stand_y);
433  int MoveQuality(int p_x, int p_y);
434  void MoveTo(int p_Vector,int p_Distance, int iterations);
435  void DoWalking(int p_Distance,int &p_Vector, int &vx, int &vy);
436  void DoWalkingCorrect(int p_Distance,int &p_Vector, int &vx, int &vy);
437  void Escape(int p_Vector,int p_Distance);
438  void CheckTraps();
439  virtual void SetLocation() {};
440  virtual void FreeLocation() {};
441  virtual bool GetLocation(int , int ) {return false;};
442 };
443 //------------------------------------------------------------------------------
444 
453 {
454 public:
455  Vole_JuvenileMale(struct_Vole_Adult * p_aVoleStruct);
456  virtual ~Vole_JuvenileMale();
457  virtual void ReInit(struct_Vole_Adult * p_aVoleStruct);
458  virtual bool OnFarmEvent(FarmToDo event);
459  virtual void BeginStep();
460  virtual void Step();
461  virtual void EndStep();
462  virtual void OnKilled();
463 protected:
464  virtual void SetLocation();
465  virtual void FreeLocation();
466  virtual bool GetLocation(int px, int py);
467  TTypeOfVoleState Dispersal(double p_OldQual, int p_Distance);
468  void DetermineTerritorySize();
469  inline bool CanFeed();
470  void st_JuvenileExplore(void);
471  void st_BecomeSubAdult(void);
473 #ifdef __VOLEPESTICIDEON
474  virtual void ModelinkPesticide();
475  virtual void ModelinkPesticide21TWA(double a_dose);
476  virtual void Vinclozolin(double a_dose);
477  virtual void GeneralOrganophosphate(double a_dose);
478  virtual void GeneralEndocrineDisruptor(double /* a_dose */);
479  virtual void GeneticDemoPesticide(double /* a_dose */);
480 
481 #endif
482 };
483 //------------------------------------------------------------------------------
484 
493 {
494 public:
495  Vole_Male(struct_Vole_Adult * p_aVoleStruct);
496  virtual void ReInit(struct_Vole_Adult * p_aVoleStruct);
497  virtual ~Vole_Male();
498  //virtual bool OnFarmEvent(FarmToDo event);
499  //virtual void BeginStep();
500  virtual void Step();
501  virtual void EndStep();
502 protected:
503  VoleDispersalReturns Dispersal(double p_OldQual, int p_Distance);
504  void DetermineTerritorySize();
505  inline bool CanFeed();
506  int st_Maturation(void);
507  void st_Infanticide(void);
508  virtual bool MortalityTest();
510 #ifdef __VOLEPESTICIDEON
511  virtual void ModelinkPesticide();
512  virtual void ModelinkPesticide21TWA(double a_dose);
513  virtual void Vinclozolin(double a_dose);
514  virtual void GeneralOrganophosphate(double a_dose);
515  virtual void GeneralEndocrineDisruptor(double /* a_dose */);
516  virtual void GeneticDemoPesticide(double /* a_dose */);
517 #endif
518 };
519 //------------------------------------------------------------------------------
520 
529 {
530 public:
531  Vole_JuvenileFemale(struct_Vole_Adult * p_aVoleStruct);
532  virtual void ReInit(struct_Vole_Adult * p_aVoleStruct);
533  virtual ~Vole_JuvenileFemale();
534  virtual bool OnFarmEvent(FarmToDo event);
535  virtual void BeginStep();
536  virtual void Step();
537  virtual void EndStep();
538  virtual void OnKilled();
539 protected:
540  // Methods
541  int Dispersal(double p_OldQual, int p_Distance);
542  int st_Evaluate_n_Explore();
543  void st_BecomeSubAdult(void);
544  //unsigned HowManyOldFemales(int p_x, int p_y);
545  virtual void SetLocation();
546  virtual void FreeLocation();
547  virtual bool GetLocation(int px, int py);
548 #ifdef __VOLEPESTICIDEON
549  double m_maturitydelay;
550  virtual void ModelinkPesticide();
551  virtual void ModelinkPesticide21TWA(double a_dose);
552  virtual void Vinclozolin(double a_dose);
553  virtual void GeneralOrganophosphate(double a_dose);
554  virtual void GeneralEndocrineDisruptor(double /* a_dose */);
555  virtual void GeneticDemoPesticide(double /* a_dose */);
556 public:
557  void SetMaturityDelay(double a_delay) { m_maturitydelay = a_delay; }
558 #endif
559 };
560 //---------------------------------------------------------------------------
561 
562 
571 {
572 public:
573  Vole_Female(struct_Vole_Adult * p_aVoleStruct);
574  void ReInit(struct_Vole_Adult * p_aVoleStruct);
575  virtual ~Vole_Female();
576  virtual void Step();
577  int SupplyNoOfYoung() {return m_NoOfYoung;};
578 
579  int SupplyMateId() {return m_MatesIdNo;};
580  int SupplyMateSB() {return m_MateLive;};
581 
582  unsigned SupplyYoungAge() {return m_YoungAge;};
583  bool SupplyPregnant() {return m_Pregnant;};
584 
585  void Set_MateState(int MateState) {m_MateLive = MateState;};
586  void OnInfanticideAttempt();
587 protected:
588 //Attributes
589 
611  unsigned m_YoungAge;
617 
618  // Methods
624  int st_Evaluate_n_Explore();
625  int st_Special_Explore();
627 #ifdef __VOLEPESTICIDEON
628  unsigned int m_pesticideloadindex;
629  double m_pesticideloadarray[21];
630  virtual void ModelinkPesticide();
631  virtual void ModelinkPesticide21TWA(double a_dose);
632  virtual void Vinclozolin(double a_dose);
633  virtual void GeneralOrganophosphate(double a_dose);
634  virtual void GeneralEndocrineDisruptor(double /* a_dose */);
635  static int m_EndoCrineDisruptionGestationLength;
636  virtual void GeneticDemoPesticide(double /* a_dose */);
637 #endif
638 };
639 //---------------------------------------------------------------------------
640 #endif
Vole_Base::SupplyXBorn
int SupplyXBorn()
Definition: vole_all.h:348
Vole_Base::m_LifeSpan
int m_LifeSpan
Definition: vole_all.h:190
Vole_Base::Set_ElemBorn
void Set_ElemBorn(int a_Location_x, int a_Location_y)
Definition: vole_all.h:315
vob_JuvenileFemale
Definition: vole_all.h:101
Vole_Base::RodenticideIngestion
virtual void RodenticideIngestion(void)
Definition: Vole_all.cpp:3343
Vole_Base::m_MotherId
unsigned m_MotherId
Definition: vole_all.h:166
TTypeOfVoleState
TTypeOfVoleState
Vole behavioural states.
Definition: vole_all.h:55
Vole_Base::~Vole_Base
virtual ~Vole_Base()
Definition: Vole_all.cpp:304
GeneticMaterial::UnsetGeneticFlag
void UnsetGeneticFlag()
Definition: GeneticMaterial.cpp:178
Vole_Base::m_ElemBorn
int m_ElemBorn
Definition: vole_all.h:186
Vole_Base::SupplyTotNoYoung
int SupplyTotNoYoung()
Definition: vole_all.h:346
Vole_Base::m_FHabQualThreshold2
static double m_FHabQualThreshold2
Definition: vole_all.h:237
Vole_Base::CurrentVState
TTypeOfVoleState CurrentVState
Definition: vole_all.h:407
Vole_Base::m_MHabQualThreshold2
static double m_MHabQualThreshold2
Definition: vole_all.h:243
Vole_Base::SupplyElemBorn
int SupplyElemBorn()
Definition: vole_all.h:354
Landscape::SupplyVegType
TTypesOfVegetation SupplyVegType(int a_x, int a_y)
Definition: Landscape.h:1321
tovs_MDying
Definition: vole_all.h:63
Landscape::SupplyElementType
TTypesOfLandscapeElement SupplyElementType(int a_polyref)
Definition: Landscape.h:1110
Vole_Base::m_MinTerrRange
unsigned int m_MinTerrRange
Definition: vole_all.h:164
Vole_Female::SupplyMateId
int SupplyMateId()
Definition: vole_all.h:579
Vole_Base::WhatState
virtual int WhatState()
Definition: vole_all.h:332
Vole_Base::MoveTo
void MoveTo(int p_Vector, int p_Distance, int iterations)
Movement.
Definition: Vole_all.cpp:907
Vole_Base::SupplyY
unsigned SupplyY()
Definition: vole_all.h:374
Vole_Base::UnsetGeneticFlag
void UnsetGeneticFlag()
Definition: vole_all.h:398
tovs_GiveBirth
Definition: vole_all.h:68
Vole_Base
Base class for voles - all vole objects are descended from this class.
Definition: vole_all.h:152
vob_Female
Definition: vole_all.h:103
Vole_Base::m_BirthYear
int m_BirthYear
Definition: vole_all.h:157
Vole_Base::CheckTraps
void CheckTraps()
Definition: Vole_all.cpp:2800
Vole_JuvenileMale::SetLocation
virtual void SetLocation()
Map location function.
Definition: Vole_all.cpp:3076
Vole_Base::m_VegBorn
int m_VegBorn
Definition: vole_all.h:188
tovs_ReproBehaviour
Definition: vole_all.h:66
Vole_JuvenileMale::st_Eval_n_Explore
TTypeOfVoleState st_Eval_n_Explore(void)
JuvenileMale vole main territory assessment behaviour.
Definition: Vole_all.cpp:3209
tovs_FEvaluateExplore
Definition: vole_all.h:65
Vole_Female::m_MatesGenes
GeneticMaterial m_MatesGenes
The DNA passed from the male on mating.
Definition: vole_all.h:616
Vole_Base::m_Mature
bool m_Mature
Definition: vole_all.h:176
Vole_JuvenileMale::Dispersal
TTypeOfVoleState Dispersal(double p_OldQual, int p_Distance)
JuvenileMale vole dispersal behaviour.
Definition: Vole_all.cpp:3237
struct_Vole_Adult::FatherStateAtBirth
int FatherStateAtBirth
Definition: vole_all.h:137
Vole_Base::SupplyTrapPosition
InTrapPosition SupplyTrapPosition()
Definition: vole_all.h:378
Vole_Base::SupplyInTrap
bool SupplyInTrap()
Definition: vole_all.h:376
vob_JuvenileMale
Definition: vole_all.h:100
Vole_Base::UnsetDirectFlag
void UnsetDirectFlag()
Definition: vole_all.h:400
Vole_JuvenileFemale::EndStep
virtual void EndStep()
Female vole EndStep.
Definition: Vole_all.cpp:1474
Vole_Base::Setm_Mature
void Setm_Mature()
Definition: vole_all.h:300
Vole_Base::SupplyX
unsigned SupplyX()
Definition: vole_all.h:372
Landscape::BackTranslateVegTypes
int BackTranslateVegTypes(TTypesOfVegetation VegReference)
Definition: Landscape.h:1669
Vole_Base::ReInit
virtual void ReInit(struct_Vole_Adult *p_aVoleStruct)
Definition: Vole_all.cpp:235
vob_Male
Definition: vole_all.h:102
TAnimal::m_OurLandscape
Landscape * m_OurLandscape
Definition: PopulationManager.h:229
GeneticMaterial::HeterozygosityCount
int HeterozygosityCount()
Definition: GeneticMaterial.cpp:328
Vole_Base::m_MinJMVoleHabQual
static double m_MinJMVoleHabQual
Definition: vole_all.h:226
Vole_JuvenileFemale::ReInit
virtual void ReInit(struct_Vole_Adult *p_aVoleStruct)
Definition: Vole_all.cpp:1363
Vole_Female::st_Evaluate_n_Explore
int st_Evaluate_n_Explore()
Main territory evaluation behaviour.
Definition: Vole_all.cpp:2228
tovs_UpdateGestation
Definition: vole_all.h:71
Vole_JuvenileFemale::GetLocation
virtual bool GetLocation(int px, int py)
Location map function.
Definition: Vole_all.cpp:1799
Vole_Base::SetDirectFlag
void SetDirectFlag()
Definition: vole_all.h:396
Vole_Base::GetFertile
bool GetFertile()
Get the male vole fertility.
Definition: vole_all.h:424
struct_Vole_Adult
A struct for passing data to create a new vole.
Definition: vole_all.h:122
Vole_Female::SupplyYoungAge
unsigned SupplyYoungAge()
Definition: vole_all.h:582
Vole_Base::SetWeight
void SetWeight(double W)
Definition: vole_all.h:298
Vole_Female::Set_MateState
void Set_MateState(int MateState)
Definition: vole_all.h:585
Vole_Base::m_MyGenes
GeneticMaterial m_MyGenes
Definition: vole_all.h:213
tovs_Infanticide
Definition: vole_all.h:62
Vole_Base::SupplyElemType
TTypesOfLandscapeElement SupplyElemType()
Definition: vole_all.h:356
Vole_Female::m_YoungAge
unsigned m_YoungAge
The age of current litter in days.
Definition: vole_all.h:611
Vole_JuvenileMale::GetLocation
virtual bool GetLocation(int px, int py)
Map location function.
Definition: Vole_all.cpp:3094
Vole_Base::SupplyIDNo
int SupplyIDNo()
Definition: vole_all.h:364
Vole_Base::m_FHabQualThreshold1
static double m_FHabQualThreshold1
Definition: vole_all.h:239
Vole_Male::ReInit
virtual void ReInit(struct_Vole_Adult *p_aVoleStruct)
Definition: Vole_all.cpp:2424
GeneticMaterial::UnsetDirectFlag
void UnsetDirectFlag()
Definition: GeneticMaterial.cpp:182
struct_Vole_Adult::weight
double weight
Definition: vole_all.h:128
Vole_Base::Set_MotherId
void Set_MotherId(unsigned MotherIdNo)
Definition: vole_all.h:305
Vole_JuvenileFemale
The class for female voles.
Definition: vole_all.h:528
tovs_SpecialExplore
Definition: vole_all.h:72
tovs_InitialState
Definition: vole_all.h:57
GeneticMaterial::GetDirectFlag
uint32 GetDirectFlag()
Definition: GeneticMaterial.cpp:191
Vole_Base::Set_XBorn
void Set_XBorn(int a_Location_x)
Definition: vole_all.h:311
Vole_Base::m_PolyRefBorn
int m_PolyRefBorn
Definition: vole_all.h:184
Vole_Base::GetLocation
virtual bool GetLocation(int, int)
Definition: vole_all.h:441
Vole_Base::m_Have_Territory
bool m_Have_Territory
Definition: vole_all.h:204
Vole_Female::~Vole_Female
virtual ~Vole_Female()
Definition: Vole_all.cpp:1891
Vole_Base::EndStep
virtual void EndStep()
All voles age at the end of the day.
Definition: Vole_all.cpp:336
Vole_Base::m_Weight
double m_Weight
Definition: vole_all.h:192
Vole_Base::SetFree
void SetFree()
Definition: vole_all.h:380
Vole_Female::SupplyMateSB
int SupplyMateSB()
Definition: vole_all.h:580
GeneticMaterial::SetDirectFlag
void SetDirectFlag()
Definition: GeneticMaterial.cpp:173
tovs_JuvenileExploration
Definition: vole_all.h:59
Vole_Base::Set_YBorn
void Set_YBorn(int a_Location_y)
Definition: vole_all.h:313
Vole_Base::m_MaxFemaleTerritorySize
static unsigned int m_MaxFemaleTerritorySize
Definition: vole_all.h:218
Vole_Base::SupplyAge
unsigned SupplyAge()
Definition: vole_all.h:370
Vole_Base::Set_VegBorn
void Set_VegBorn(int a_Location_x, int a_Location_y)
Definition: vole_all.h:321
Vole_JuvenileFemale::st_Evaluate_n_Explore
int st_Evaluate_n_Explore()
Main territory evaluation behaviour.
Definition: Vole_all.cpp:1760
Vole_Female::m_NoOfYoung
int m_NoOfYoung
The number of young in the current litter (if one).
Definition: vole_all.h:596
vob_foobar
Definition: vole_all.h:104
Vole_Female
The class for female voles.
Definition: vole_all.h:570
struct_Vole_Adult::xborn
int xborn
Definition: vole_all.h:129
Vole_Male::st_Maturation
int st_Maturation(void)
Male vole maturation control.
Definition: Vole_all.cpp:2549
Vole_JuvenileFemale::Dispersal
int Dispersal(double p_OldQual, int p_Distance)
Female dispersal.
Definition: Vole_all.cpp:1817
Vole_JuvenileMale::~Vole_JuvenileMale
virtual ~Vole_JuvenileMale()
Definition: Vole_all.cpp:3333
Vole_Female::st_Lactating
TTypeOfVoleState st_Lactating()
Lactation.
Definition: Vole_all.cpp:2090
tovs_Mating
Definition: vole_all.h:70
Landscape
The landscape class containing all environmental and topographical data.
Definition: Landscape.h:112
Vole_Male::CanFeed
bool CanFeed()
Currently not used.
Definition: Vole_all.cpp:2793
VoleDispersalReturns
VoleDispersalReturns
Definition: vole_all.h:78
Vole_Female::m_MatesIdNo
int m_MatesIdNo
Definition: vole_all.h:591
Vole_Base::FreeLocation
virtual void FreeLocation()
Definition: vole_all.h:440
GeneticMaterial
Class for the genetic material optionally carried by animals in ALMaSS.
Definition: GeneticMaterial.h:94
Vole_Base::MoveQuality
int MoveQuality(int p_x, int p_y)
Test a location for quality while moving.
Definition: Vole_all.cpp:1207
Vole_Base::m_MaleTerritoryRangeSlope
static double m_MaleTerritoryRangeSlope
Definition: vole_all.h:230
Vole_JuvenileFemale::st_BecomeSubAdult
void st_BecomeSubAdult(void)
Definition: Vole_all.cpp:1725
Vole_Base::Set_Age
void Set_Age(int Age)
Definition: vole_all.h:329
struct_Vole_Adult::m_gflag
bool m_gflag
Definition: vole_all.h:143
Vole_JuvenileMale::DetermineTerritorySize
void DetermineTerritorySize()
Vole_Female::st_Special_Explore
int st_Special_Explore()
Post weaning territory expansion.
Definition: Vole_all.cpp:2273
Vole_Base::m_XBorn
int m_XBorn
Definition: vole_all.h:180
struct_Vole_Adult::misc_use
double misc_use
Definition: vole_all.h:145
Vole_Base::SupplyMyAllele
uint32 SupplyMyAllele(int i, int j)
Definition: vole_all.h:387
TTypesOfVegetation
TTypesOfVegetation
Definition: tov_declaration.h:30
struct_Vole_Adult::Genes
GeneticMaterial Genes
Definition: vole_all.h:141
TAnimal::m_Location_y
int m_Location_y
Definition: PopulationManager.h:228
Vole_Base::SupplyYBorn
int SupplyYBorn()
Definition: vole_all.h:350
tovs_FDying
Definition: vole_all.h:73
Vole_Female::st_ReproBehaviour
TTypeOfVoleState st_ReproBehaviour()
Reproductive switch.
Definition: Vole_all.cpp:1974
vdisp_CarryOn
Definition: vole_all.h:79
AlleleFreq
Class to handle statistics and constructs based on allele frequencies.
Definition: GeneticMaterial.h:61
Vole_Base::m_MinMaleTerritorySize
static unsigned int m_MinMaleTerritorySize
Definition: vole_all.h:220
struct_Vole_Adult::FatherId
int FatherId
Definition: vole_all.h:135
TAnimal
The base class for all ALMaSS animal classes.
Definition: PopulationManager.h:205
Vole_Base::SupplyGenes
GeneticMaterial SupplyGenes()
Definition: vole_all.h:402
Vole_Base::SupplyTerritorial
bool SupplyTerritorial()
Definition: vole_all.h:336
Vole_Male::EndStep
virtual void EndStep()
Male vole EndStep.
Definition: Vole_all.cpp:2490
Vole_Base::SupplyWeight
double SupplyWeight()
Definition: vole_all.h:362
tovs_FMaturation
Definition: vole_all.h:69
vdisp_Die
Definition: vole_all.h:80
struct_Vole_Adult::VPM
Vole_Population_Manager * VPM
Definition: vole_all.h:139
AnimalPosition
A class defining an animals position.
Definition: PopulationManager.h:168
Vole_Base::SupplyHeteroZyg
int SupplyHeteroZyg()
Definition: vole_all.h:384
Vole_JuvenileFemale::~Vole_JuvenileFemale
virtual ~Vole_JuvenileFemale()
Definition: Vole_all.cpp:1378
Vole_Base::m_DispVector
int m_DispVector
Definition: vole_all.h:202
GeneticMaterial::GetGeneticFlag
uint32 GetGeneticFlag()
Definition: GeneticMaterial.cpp:187
Vole_Base::SupplyDeathCause
int SupplyDeathCause()
Definition: vole_all.h:368
struct_Vole_Adult::BirthYear
int BirthYear
Definition: vole_all.h:134
Vole_Base::DoWalking
void DoWalking(int p_Distance, int &p_Vector, int &vx, int &vy)
Walking.
Definition: Vole_all.cpp:953
Vole_Base::GetGeneticFlag
int GetGeneticFlag()
Definition: vole_all.h:390
Vole_Base::m_MinFVoleHabQual
static double m_MinFVoleHabQual
Definition: vole_all.h:224
Vole_Base::m_FHabQualThreshold3
static double m_FHabQualThreshold3
Definition: vole_all.h:235
Vole_Female::SupplyNoOfYoung
int SupplyNoOfYoung()
Definition: vole_all.h:577
Vole_Base::SupplyMature
bool SupplyMature()
Definition: vole_all.h:366
Vole_JuvenileFemale::OnFarmEvent
virtual bool OnFarmEvent(FarmToDo event)
External event handler.
Definition: Vole_all.cpp:1529
Vole_Base::m_MHabQualThreshold3
static double m_MHabQualThreshold3
Definition: vole_all.h:241
Vole_Base::SupplyMotherId
int SupplyMotherId()
Definition: vole_all.h:340
Vole_Base::st_Dying
void st_Dying()
All voles end here on death.
Definition: Vole_all.cpp:348
GeneticMaterial::GetAllele
uint32 GetAllele(int pos, int Chromosome)
Definition: GeneticMaterial.cpp:233
Vole_Base::m_Sex
bool m_Sex
Definition: vole_all.h:174
Vole_JuvenileFemale::OnKilled
virtual void OnKilled()
Death from external entity.
Definition: Vole_all.cpp:1718
Vole_JuvenileMale::OnKilled
virtual void OnKilled()
JuvenileMale vole death by external entity.
Definition: Vole_all.cpp:3302
Vole_Male::~Vole_Male
virtual ~Vole_Male()
Definition: Vole_all.cpp:2435
Vole_Female::m_MateLive
int m_MateLive
Definition: vole_all.h:590
Vole_Base::Vole_Base
Vole_Base(struct_Vole_Adult *p_aVoleStruct)
Constructor for Vole_Base.
Definition: Vole_all.cpp:228
Vole_Male::st_Infanticide
void st_Infanticide(void)
Male vole infanticide behaviour.
Definition: Vole_all.cpp:2568
Vole_JuvenileMale::Step
virtual void Step()
Juvenile Male vole Step.
Definition: Vole_all.cpp:3141
Vole_Base::m_MaxMaleTerritorySize
static unsigned int m_MaxMaleTerritorySize
Definition: vole_all.h:216
Vole_Female::m_Pregnant
bool m_Pregnant
A flag indicating whether pregnant or not.
Definition: vole_all.h:601
Vole_Base::IDNo
unsigned IDNo
Definition: vole_all.h:208
Vole_Base::CalculateCarryingCapacity
double CalculateCarryingCapacity(int x, int y, int a_ddep)
Definition: Vole_all.cpp:384
struct_Vole_Adult::y
int y
Definition: vole_all.h:126
Vole_JuvenileFemale::Step
virtual void Step()
JuvenileFemale vole Step.
Definition: Vole_all.cpp:1426
GeneticMaterial.h
GeneticMaterial.h This file contains the headers for the genetic material classes
GeneticMaterial256_16
Definition: GeneticMaterial.h:192
Vole_Female::st_BecomeReproductive
TTypeOfVoleState st_BecomeReproductive()
Female vole maturation control.
Definition: Vole_all.cpp:2005
Vole_JuvenileMale::OnFarmEvent
virtual bool OnFarmEvent(FarmToDo event)
JuvenileMale vole exernal event handler.
Definition: Vole_all.cpp:2887
Vole_Base::DoWalkingCorrect
void DoWalkingCorrect(int p_Distance, int &p_Vector, int &vx, int &vy)
Walking where there is a danger of stepping off the world.
Definition: Vole_all.cpp:1041
Vole_Population_Manager
The class to handle all vole population related matters.
Definition: VolePopulationManager.h:151
struct_Vole_Adult::L
Landscape * L
Definition: vole_all.h:138
TAnimal::CopyMyself
virtual void CopyMyself()
Definition: PopulationManager.h:224
Vole_Base::SupplyTerrRange
int SupplyTerrRange()
Definition: vole_all.h:360
Vole_Base::SimW
int SimW
Definition: vole_all.h:210
Vole_Male::Vole_Male
Vole_Male(struct_Vole_Adult *p_aVoleStruct)
Vole_Male constructor.
Definition: Vole_all.cpp:2413
Vole_JuvenileMale::FreeLocation
virtual void FreeLocation()
Map location function.
Definition: Vole_all.cpp:3085
Vole_JuvenileFemale::FreeLocation
virtual void FreeLocation()
Location map function.
Definition: Vole_all.cpp:1792
Vole_Male::DetermineTerritorySize
void DetermineTerritorySize()
Calculates the territory size needed for a vole of his weight.
Definition: Vole_all.cpp:2778
Vole_Base::Step
virtual void Step()
Step behaviour - must be implemented in descendent classes.
Definition: vole_all.h:291
Vole_Base::Set_PolyRefBorn
void Set_PolyRefBorn(int a_Location_x, int a_Location_y)
Definition: vole_all.h:327
Vole_JuvenileMale
The class for juvenile male voles.
Definition: vole_all.h:452
Vole_Base::BeginStep
virtual void BeginStep()
BeingStep behaviour - must be implemented in descendent classes.
Definition: vole_all.h:290
Vole_Base::SimH
int SimH
Definition: vole_all.h:210
Vole_JuvenileMale::st_BecomeSubAdult
void st_BecomeSubAdult(void)
Definition: Vole_all.cpp:3264
Vole_Base::Set_NoYoungTot
void Set_NoYoungTot(int a_NoOfYoung)
Definition: vole_all.h:309
vdisp_Infanticide
Definition: vole_all.h:82
Vole_JuvenileMale::Vole_JuvenileMale
Vole_JuvenileMale(struct_Vole_Adult *p_aVoleStruct)
Vole_JuvenileMale constructor.
Definition: Vole_all.cpp:3313
Vole_JuvenileMale::CanFeed
bool CanFeed()
Vole_Base::m_intrappos
InTrapPosition m_intrappos
Definition: vole_all.h:214
Vole_JuvenileMale::ReInit
virtual void ReInit(struct_Vole_Adult *p_aVoleStruct)
Definition: Vole_all.cpp:3323
Vole_JuvenileMale::EndStep
virtual void EndStep()
Juvenile Male vole EndStep.
Definition: Vole_all.cpp:3181
Vole_Base::Escape
void Escape(int p_Vector, int p_Distance)
Dispersal - directed movement.
Definition: Vole_all.cpp:1127
Vole_Base::Set_BirthYear
void Set_BirthYear(int BirthYear)
Definition: vole_all.h:302
InTrapPosition
A class for storing the position of the trap the vole is in.
Definition: vole_all.h:112
Vole_Base::m_OurPopulation
Vole_Population_Manager * m_OurPopulation
Definition: vole_all.h:408
struct_Vole_Adult::MotherId
int MotherId
Definition: vole_all.h:136
Vole_Male
The class for male voles.
Definition: vole_all.h:492
VoleObject
VoleObject
Definition: vole_all.h:98
Vole_Base::m_Age
int m_Age
Definition: vole_all.h:178
TTypesOfLandscapeElement
TTypesOfLandscapeElement
Definition: tole_declaration.h:36
Vole_JuvenileFemale::Vole_JuvenileFemale
Vole_JuvenileFemale(struct_Vole_Adult *p_aVoleStruct)
Vole_JuvenileFemale constructor.
Definition: Vole_all.cpp:1349
Vole_Female::Step
virtual void Step()
Female vole Step.
Definition: Vole_all.cpp:1906
Vole_Base::m_MinMVoleHabQual
static double m_MinMVoleHabQual
Definition: vole_all.h:228
Vole_Base::Set_FatherId
void Set_FatherId(unsigned FatherIdNo)
Definition: vole_all.h:307
struct_Vole_Adult::VegBorn
int VegBorn
Definition: vole_all.h:133
Vole_Female::Vole_Female
Vole_Female(struct_Vole_Adult *p_aVoleStruct)
Vole_Female constructor.
Definition: Vole_all.cpp:1852
Vole_Base::m_YBorn
int m_YBorn
Definition: vole_all.h:182
Vole_Male::Step
virtual void Step()
Male vole Step.
Definition: Vole_all.cpp:2450
Vole_Base::SupplyHomoZyg
int SupplyHomoZyg()
Definition: vole_all.h:382
GeneticMaterial::SetGeneticFlag
void SetGeneticFlag()
Definition: GeneticMaterial.cpp:169
Vole_Base::m_BornLastYear
bool m_BornLastYear
A flag set if the female was born the year before.
Definition: vole_all.h:162
Vole_Base::Init
virtual void Init(struct_Vole_Adult *p_aVoleStruct)
Definition: Vole_all.cpp:240
Vole_Base::OnKilled
virtual void OnKilled()
Definition: vole_all.h:404
Vole_Female::st_UpdateGestation
TTypeOfVoleState st_UpdateGestation()
Gestation control.
Definition: Vole_all.cpp:1991
Vole_Female::m_DaysUntilBirth
int m_DaysUntilBirth
A counter counting down gestation days.
Definition: vole_all.h:606
InTrapPosition::m_inAtrap
bool m_inAtrap
Definition: vole_all.h:115
Vole_Female::st_Mating
TTypeOfVoleState st_Mating()
Female mating.
Definition: Vole_all.cpp:2341
Vole_Base::m_FemaleTerritoryRangeSlope
static double m_FemaleTerritoryRangeSlope
Definition: vole_all.h:232
Vole_Base::m_Death
int m_Death
Definition: vole_all.h:170
Vole_Female::st_GiveBirth
TTypeOfVoleState st_GiveBirth()
Litter production.
Definition: Vole_all.cpp:2024
Vole_JuvenileMale::BeginStep
virtual void BeginStep()
Juvenile Male vole BeginStep.
Definition: Vole_all.cpp:3108
Vole_Base::SupplySex
bool SupplySex()
Definition: vole_all.h:342
GeneticMaterial::HomozygosityCount
int HomozygosityCount()
Definition: GeneticMaterial.cpp:317
struct_Vole_Adult::m_flag
bool m_flag
Definition: vole_all.h:142
tovs_Lactating
Definition: vole_all.h:67
Vole_Base::m_MHabQualThreshold1
static double m_MHabQualThreshold1
Definition: vole_all.h:245
Vole_Base::SetGeneticFlag
void SetGeneticFlag()
Definition: vole_all.h:394
Vole_Base::m_FatherId
unsigned m_FatherId
Definition: vole_all.h:168
struct_Vole_Adult::x
int x
Definition: vole_all.h:125
struct_Vole_Adult::yborn
int yborn
Definition: vole_all.h:130
FarmToDo
FarmToDo
Definition: treatment.h:31
Vole_Base::SupplyBornLastYear
bool SupplyBornLastYear()
Were we born this year?
Definition: vole_all.h:334
Vole_Female::ReInit
void ReInit(struct_Vole_Adult *p_aVoleStruct)
Definition: Vole_all.cpp:1870
tovs_MMaturation
Definition: vole_all.h:60
Vole_Female::OnInfanticideAttempt
void OnInfanticideAttempt()
Determines whether an infanticide attempt will succeed.
Definition: Vole_all.cpp:2380
Vole_JuvenileFemale::SetLocation
virtual void SetLocation()
Location map function.
Definition: Vole_all.cpp:1785
Vole_Base::GetDirectFlag
int GetDirectFlag()
Definition: vole_all.h:392
Vole_JuvenileFemale::BeginStep
virtual void BeginStep()
Female vole BeginStep.
Definition: Vole_all.cpp:1393
vdisp_Mature
Definition: vole_all.h:81
struct_Vole_Adult::ElemBorn
int ElemBorn
Definition: vole_all.h:132
struct_Vole_Adult::age
int age
Definition: vole_all.h:127
Vole_Base::m_MinFemaleTerritorySize
static unsigned int m_MinFemaleTerritorySize
Definition: vole_all.h:222
Vole_Male::st_Eval_n_Explore
TTypeOfVoleState st_Eval_n_Explore(void)
Male vole main territory assessment behaviour.
Definition: Vole_all.cpp:2584
Vole_Base::SupplyAllele
int SupplyAllele(int locus, int allele)
Definition: vole_all.h:386
Vole_Male::MortalityTest
virtual bool MortalityTest()
Do a mortality test.
Definition: Vole_all.cpp:2763
AlleleFreq1616
Definition: GeneticMaterial.h:125
Vole_Base::MortalityTest
virtual bool MortalityTest()
Do a mortality test.
Definition: Vole_all.cpp:362
Vole_Base::m_fertile
bool m_fertile
Flag indicating the fertility state (true means fertile)
Definition: vole_all.h:194
Vole_Base::m_TerrRange
int m_TerrRange
Definition: vole_all.h:172
Vole_Base::m_Reserves
int m_Reserves
Definition: vole_all.h:206
TAnimal::m_Location_x
int m_Location_x
Definition: PopulationManager.h:225
Vole_Female::SupplyPregnant
bool SupplyPregnant()
Definition: vole_all.h:583
Vole_Base::SetFertile
void SetFertile(bool f)
Set the male vole fertility.
Definition: vole_all.h:414
Landscape::SupplyPolyRef
int SupplyPolyRef(int a_x, int a_y)
Definition: Landscape.h:1488
Vole_Male::Dispersal
VoleDispersalReturns Dispersal(double p_OldQual, int p_Distance)
Male vole dispersal behaviour.
Definition: Vole_all.cpp:2689
Vole_Base::m_BreedingSeason
static bool m_BreedingSeason
Definition: vole_all.h:247
struct_Vole_Adult::m_dflag
bool m_dflag
Definition: vole_all.h:144
Vole_Base::SupplyBirthYear
int SupplyBirthYear()
Definition: vole_all.h:344
Vole_Base::SupplyVegBorn
int SupplyVegBorn()
Definition: vole_all.h:358
Vole_Base::SetBreedingSeason
void SetBreedingSeason(bool a_flag)
Set Breeding Season flag.
Definition: vole_all.h:296
Vole_Base::SetLocation
virtual void SetLocation()
Definition: vole_all.h:439
tovs_MEvaluateExplore
Definition: vole_all.h:61
GeneticMaterial1616
Definition: GeneticMaterial.h:153
Vole_Base::SupplyFatherId
int SupplyFatherId()
Definition: vole_all.h:338
Vole_Base::SupplyPolyRefBorn
int SupplyPolyRefBorn()
Definition: vole_all.h:352
Vole_JuvenileMale::st_JuvenileExplore
void st_JuvenileExplore(void)
Extra movement on weaning.
Definition: Vole_all.cpp:2873
Landscape::BackTranslateEleTypes
int BackTranslateEleTypes(TTypesOfLandscapeElement EleReference)
Definition: Landscape.h:1662
Vole_Base::m_NoOfYoungTotal
int m_NoOfYoungTotal
Definition: vole_all.h:200
struct_Vole_Adult::PolyRefBorn
int PolyRefBorn
Definition: vole_all.h:131