ALMaSS Rodenticide Model ODdox
1.0
|
#include "assert.h"
#include <cstdlib>
#include <cstring>
#include <stdio.h>
#include <stdlib.h>
#include <errno.h>
#include <iostream>
#include <fstream>
#include <time.h>
#include <cmath>
#include <vector>
#include <list>
#include <string>
#include "../BatchALMaSS/ALMaSS_Setup.h"
#include "../ALMaSSDefines.h"
#include "../Landscape/ls.h"
#include "../BatchALMaSS/MovementMap.h"
#include "../BatchALMaSS/BinaryMapBase.h"
#include "../BatchALMaSS/PopulationManager.h"
#include "../Vole/GeneticMaterial.h"
#include "../Skylark/skylarks_all.h"
#include "../Partridge/Partridge_All.h"
#include "../Partridge/Partridge_Population_Manager.h"
#include "../Vole/vole_all.h"
#include "../Vole/VolePopulationManager.h"
#include "../Vole/Predators.h"
#include "../Bembidion/bembidion_all.h"
#include "../Hare/hare_all.h"
#include "../Spider/spider_all.h"
#include "../Spider/SpiderPopulationManager.h"
#include "../MarshFritillary/MarshFritillaryHdrs.h"
#include "../GooseManagement/GooseMemoryMap.h"
#include "../GooseManagement/Goose_Base.h"
#include "../BatchALMaSS/CurveClasses.h"
#include "../Hunters/Hunters_all.h"
#include "../GooseManagement/Goose_Population_Manager.h"
#include "../RoeDeer/Roe_all.h"
#include "../RoeDeer/Roe_pop_manager.h"
#include "../Rabbit/Rabbit.h"
#include "../Rabbit/Rabbit_Population_Manager.h"
#include "../Newt/Newt.h"
#include "../Newt/Newt_Population_Manager.h"
Macros | |
#define | _CRT_SECURE_NO_DEPRECATE |
Functions | |
bool | BeginningOfMonth () |
static CfgInt | cfg_DayInMonth ("PRB_DAYINMONTH", CFG_CUSTOM, 1) |
static CfgBool | cfg_UseEasyPop ("VOLE_USEEASYPOP", CFG_CUSTOM, false) |
static CfgInt | cfg_VoleCatastrophe_interval ("VOLE_CATASTROPHE_I", CFG_CUSTOM, 365 *5) |
static CfgInt | cfg_VoleCatastrophe_mortality ("VOLE_CATASTROPHE_M", CFG_CUSTOM, 90) |
static CfgBool | cfg_VoleCatastrophe_on ("VOLE_CATASTROPHE_ON", CFG_CUSTOM, false) |
void | CloseDownSim () |
void | CreateLandscape () |
bool | CreatePopulationManager () |
void | delay (int secs) |
void | DumpVegAreaData (int a_day) |
void | FloatToDouble (double &d, float f) |
void | GetProbeInput_ini () |
void | ImpactProbeReport (int a_time) |
int | main () |
void | PredProbeReportDay0 (int a_time) |
void | ProbeReport (int a_time) |
int | random (int a_range) |
bool | ReadBatchINI () |
void | RunTheSim () |
void | SpeciesSpecificActions () |
void | SpeciesSpecificReporting () |
Variables | |
CfgBool | cfg_dumpvegjan |
CfgStr | cfg_dumpvegjanfile |
CfgBool | cfg_dumpvegjune |
CfgStr | cfg_dumpvegjunefile |
CfgBool | cfg_fixed_random_sequence |
Landscape * | g_ALandscape |
ALMaSS_MathFuncs | g_AlmassMathFuncs |
Population_Manager * | g_AManager |
char * | g_files [100] |
Hunter_Population_Manager * | g_Hunter_Population_Manager |
unsigned | g_NoOfPredProbes |
int | g_NoProbes |
PopulationManagerList | g_PopulationManagerList |
TPredator_Population_Manager * | g_PredatorManager |
char * | g_Predfiles [100] |
char | g_PredResultsDir [255] |
boost::variate_generator< base_generator_type &, boost::uniform_real<> > | g_rand_uni |
const double | g_randmaxp = RAND_MAX + 1.0 |
char | g_ResultsDir [255] |
int | g_Species |
int | g_Steps |
int | g_time |
int | g_torun |
int | g_Year |
#define _CRT_SECURE_NO_DEPRECATE |
bool BeginningOfMonth | ( | ) |
|
static |
|
static |
|
static |
|
static |
|
static |
void CloseDownSim | ( | ) |
References probe_data::CloseFile(), g_ALandscape, g_NoProbes, g_PredatorManager, Landscape::SimulationClosingActions(), and Population_Manager::TheProbe.
Referenced by main().
void CreateLandscape | ( | ) |
Referenced by main().
bool CreatePopulationManager | ( | ) |
References g_Hunter_Population_Manager, g_NoOfPredProbes, g_PredatorManager, Population_Manager::OpenTheBreedingPairsProbe(), Population_Manager::OpenTheBreedingSuccessProbe(), Population_Manager::OpenTheFledgelingProbe(), Population_Manager::SetNoProbes(), PopulationManagerList::SetPopulation(), TOP_Beetle, TOP_Goose, TOP_Hare, TOP_Hunters, TOP_MarshFritillary, TOP_Newt, TOP_Partridge, TOP_Predators, TOP_Rabbit, TOP_RoeDeer, TOP_Skylark, TOP_Spider, and TOP_Vole.
Referenced by main().
void delay | ( | int | secs | ) |
References FloatToDouble().
void DumpVegAreaData | ( | int | a_day | ) |
Referenced by Landscape::GetVegArea().
void FloatToDouble | ( | double & | d, |
float | f | ||
) |
Referenced by delay(), and VegElement::ReadBugPercentageFile().
void GetProbeInput_ini | ( | ) |
References g_files, g_NoOfPredProbes, g_NoProbes, g_PredatorManager, g_Predfiles, g_ResultsDir, probe_data::OpenFile(), Population_Manager::ProbeFileInput(), probe_data::SetFile(), Population_Manager::TheProbe, and Landscape::Warn().
Referenced by main().
void ImpactProbeReport | ( | int | a_time | ) |
Referenced by Population_Manager::Catastrophe(), and Population_Manager::SpeciesSpecificReporting().
int main | ( | ) |
References cfg_fixed_random_sequence, CloseDownSim(), CreateLandscape(), CreatePopulationManager(), GetProbeInput_ini(), ReadBatchINI(), RunTheSim(), and Landscape::SetThePopManager().
void PredProbeReportDay0 | ( | int | a_time | ) |
void ProbeReport | ( | int | a_time | ) |
Referenced by Population_Manager::Catastrophe(), and Population_Manager::SpeciesSpecificReporting().
References g_rand_uni.
Referenced by Landscape::AddBeetleBanks(), APoint::APoint(), Landscape::BorderScan(), RoadsideVerge::DoDevelopment(), Landscape::Landscape(), VegElement::RandomVegStartValues(), Landscape::ReadPolys2(), Population_Manager::Shuffle(), and UnsprayedFieldMargin::UnsprayedFieldMargin().
bool ReadBatchINI | ( | ) |
References g_files, g_NoOfPredProbes, g_NoProbes, g_Predfiles, g_PredResultsDir, and g_ResultsDir.
Referenced by main().
void RunTheSim | ( | ) |
References Landscape::DumpVegAreaData(), g_Hunter_Population_Manager, g_PredatorManager, g_torun, Population_Manager::Run(), Population_Manager::SpeciesSpecificReporting(), Landscape::SupplyDayInMonth(), Landscape::SupplyMonth(), and Landscape::TurnTheWorld().
Referenced by main().
void SpeciesSpecificActions | ( | ) |
void SpeciesSpecificReporting | ( | ) |
Referenced by Population_Manager::Catastrophe().
CfgBool cfg_dumpvegjan |
CfgStr cfg_dumpvegjanfile |
CfgBool cfg_dumpvegjune |
CfgStr cfg_dumpvegjunefile |
CfgBool cfg_fixed_random_sequence |
Referenced by main().
Landscape* g_ALandscape |
Referenced by CloseDownSim().
ALMaSS_MathFuncs g_AlmassMathFuncs |
Population_Manager* g_AManager |
char* g_files[100] |
Referenced by GetProbeInput_ini(), and ReadBatchINI().
Hunter_Population_Manager* g_Hunter_Population_Manager |
Referenced by CreatePopulationManager(), and RunTheSim().
unsigned g_NoOfPredProbes |
Referenced by CreatePopulationManager(), GetProbeInput_ini(), and ReadBatchINI().
int g_NoProbes |
Referenced by CloseDownSim(), GetProbeInput_ini(), and ReadBatchINI().
PopulationManagerList g_PopulationManagerList |
TPredator_Population_Manager* g_PredatorManager |
Referenced by CloseDownSim(), CreatePopulationManager(), GetProbeInput_ini(), and RunTheSim().
char* g_Predfiles[100] |
Referenced by GetProbeInput_ini(), and ReadBatchINI().
char g_PredResultsDir[255] |
Referenced by ReadBatchINI().
boost::variate_generator<base_generator_type&, boost::uniform_real<> > g_rand_uni |
Referenced by random().
const double g_randmaxp = RAND_MAX + 1.0 |
char g_ResultsDir[255] |
Referenced by GetProbeInput_ini(), and ReadBatchINI().
int g_Species |
int g_Steps |
int g_time |
int g_torun |
Referenced by RunTheSim().
int g_Year |