30#ifndef LCE_COMPOSITE_H
31#define LCE_COMPOSITE_H
128 return patch->
get_K(SEX);
133 double K = (double)patch->
get_K(SEX);
139 return (
unsigned int)ceil(N + r*N*((K-N)/K));
282 void do_breed (
sex_t SEX,
unsigned int size,
int* counter,
Patch* patch,
unsigned int patchNbr);
A class to manage the files associated with each components of the simulation.
Definition: fileservices.h:52
This class contains traits along with other individual information (sex, pedigree,...
Definition: individual.h:49
Performs breeding and migration in one, migration rates are backward rates.
Definition: LCEcomposite.h:46
void breed_disperse(sex_t SEX, Patch *patch, unsigned int LocalPatch, unsigned int size)
unsigned int stochasticFecundityGrowth(Patch *patch, sex_t SEX)
The number of offspring produced is a random number drawn from a Poisson distribution with mean equal...
Definition: LCEcomposite.h:174
unsigned int(LCE_Breed_Disperse::* _get_numMalOffspring)(Patch *patch)
Definition: LCEcomposite.h:61
void do_breed_disperse()
Definition: LCEcomposite.cc:241
unsigned int conditionalLogisticGrowth(Patch *patch, sex_t SEX)
The number of offspring produced depends on the adult density.
Definition: LCEcomposite.h:148
unsigned int numMalOffspring_random_colonizers(Patch *patch)
Definition: LCEcomposite.h:111
virtual bool resetParameterFromSource(std::string param, SimComponent *cmpt)
Definition: LCEcomposite.h:201
virtual age_t removeAgeClass()
Definition: LCEcomposite.h:202
Individual * mate_selfing(sex_t SEX, Patch *patch, unsigned int LocalPatch)
Definition: LCEcomposite.cc:302
virtual void loadStatServices(StatServices *loader)
Definition: LCEcomposite.h:200
LCE_Breed_Disperse()
Definition: LCEcomposite.cc:44
Individual * mate_full_selfing(sex_t SEX, Patch *patch, unsigned int LocalPatch)
Definition: LCEcomposite.cc:326
virtual LifeCycleEvent * clone()
Definition: LCEcomposite.h:198
sex_t _dispersing_sex
Which part of the population is dispersing its gametes.
Definition: LCEcomposite.h:53
unsigned int numMalOffspring_notrandom(Patch *patch)
The number of males produced is always zero when the mating system is not random mating.
Definition: LCEcomposite.h:96
unsigned int(LCE_Breed_Disperse::* _get_patchFecundity)(Patch *patch, sex_t SEX)
Definition: LCEcomposite.h:62
unsigned int conditionalStochasticLogisticGrowth(Patch *patch, sex_t SEX)
The number of offspring produced depends on the adult density, similar to 'conditionalLogisticGrowth'...
Definition: LCEcomposite.h:158
Individual * makeOffspring(Individual *ind)
Individual * mate_cloning(sex_t SEX, Patch *patch, unsigned int LocalPatch)
Definition: LCEcomposite.cc:335
unsigned int stochasticLogisticGrowth(Patch *patch, sex_t SEX)
The number of offspring produced is drawn from a Poisson with mean equal to the logistic growth predi...
Definition: LCEcomposite.h:142
virtual age_t addAgeClass()
Definition: LCEcomposite.h:203
double * _growthRates
Patch-specific growth rates.
Definition: LCEcomposite.h:56
unsigned int numFemOffspring(Patch *patch)
Definition: LCEcomposite.h:74
void(LCE_Breed_Disperse::* _breed_disperse)()
Definition: LCEcomposite.h:47
virtual ~LCE_Breed_Disperse()
Definition: LCEcomposite.h:68
virtual age_t requiredAgeClass()
Definition: LCEcomposite.h:204
unsigned int numFemOffspring_colonizers(Patch *patch)
The number of females produced in case a max number of colonizers was specified.
Definition: LCEcomposite.h:83
unsigned int fixedFecundityGrowth(Patch *patch, sex_t SEX)
The number of offspring produced is equal to the carrying capacity multiplied by the mean fecundity o...
Definition: LCEcomposite.h:168
Individual *(LCE_Breed_Disperse::* _make_offspring)(sex_t SEX, Patch *patch, unsigned int LocalPatch)
Definition: LCEcomposite.h:59
unsigned int numMalOffspring_random(Patch *patch)
Definition: LCEcomposite.h:101
Individual * mate_random(sex_t SEX, Patch *patch, unsigned int LocalPatch)
Definition: LCEcomposite.cc:283
int _num_colonizers
Maximum size of a patch after colonisation.
Definition: LCEcomposite.h:50
unsigned int logisticGrowth(Patch *patch, sex_t SEX)
The number of offspring produced is given by the logistic growth function.
Definition: LCEcomposite.h:131
Individual * get_parent(sex_t SEX, sex_t DispSex, Patch *LocalPatch, unsigned int patchNbr)
Definition: LCEcomposite.cc:343
virtual bool setParameters()
Definition: LCEcomposite.cc:60
virtual void loadFileServices(FileServices *loader)
Definition: LCEcomposite.h:199
unsigned int(LCE_Breed_Disperse::* _get_numFemOffspring)(Patch *patch)
Definition: LCEcomposite.h:60
virtual void execute()
Definition: LCEcomposite.cc:212
Individual * mate_random_hermaphrodite(sex_t SEX, Patch *patch, unsigned int LocalPatch)
Definition: LCEcomposite.cc:292
unsigned int instantGrowth(Patch *patch, sex_t SEX)
The number of offspring produced corresponds to the carrying capacity of the patch.
Definition: LCEcomposite.h:126
void do_breed_disperse_propagule()
Definition: LCEcomposite.cc:275
Composite LCE performing breeding, migration and viability selection all in one.
Definition: LCEcomposite.h:268
virtual void execute()
Definition: LCEcomposite.cc:420
virtual void loadStatServices(StatServices *loader)
Definition: LCEcomposite.cc:413
void breed_selection_disperse_propagule(int *counter)
Definition: LCEcomposite.cc:496
LCE_Breed_Selection_Disperse()
Definition: LCEcomposite.cc:382
virtual void loadFileServices(FileServices *loader)
Definition: LCEcomposite.h:290
virtual ~LCE_Breed_Selection_Disperse()
Definition: LCEcomposite.h:277
virtual age_t removeAgeClass()
Definition: LCEcomposite.h:293
virtual LifeCycleEvent * clone()
Definition: LCEcomposite.h:289
void do_breed(sex_t SEX, unsigned int size, int *counter, Patch *patch, unsigned int patchNbr)
Definition: LCEcomposite.cc:504
virtual bool setParameters()
Definition: LCEcomposite.cc:391
virtual bool resetParameterFromSource(std::string param, SimComponent *cmpt)
Definition: LCEcomposite.h:292
void(LCE_Breed_Selection_Disperse::* _breed_selection_disperse)(int *counter)
Definition: LCEcomposite.h:271
virtual age_t addAgeClass()
Definition: LCEcomposite.h:294
virtual age_t requiredAgeClass()
Definition: LCEcomposite.h:295
void breed_selection_disperse(int *counter)
Definition: LCEcomposite.cc:457
Composite LCE implementing breeding and viability selection on a given trait type.
Definition: LCEcomposite.h:214
void do_breed_selection_WrightFisher_1sex(Patch *patch, unsigned int patchID, unsigned int *cntr)
Definition: LCEcomposite.cc:808
virtual bool setParameters()
Definition: LCEcomposite.cc:538
virtual LifeCycleEvent * clone()
Definition: LCEcomposite.h:249
void do_breed_selection_FecFitness(Patch *patch, unsigned int patchID, unsigned int *cntr)
Definition: LCEcomposite.cc:693
void do_breed_selection_WrightFisher_2sex(Patch *patch, unsigned int patchID, unsigned int *cntr)
Definition: LCEcomposite.cc:739
virtual age_t addAgeClass()
Definition: LCEcomposite.h:254
Individual * makeOffspringWithSelection(Individual *ind, unsigned int natalpatch)
Performs viability selection and breeding at the same time.
Definition: LCEcomposite.cc:880
vector< unsigned int > _nonSelectedTraitIndices
Definition: LCEcomposite.h:220
virtual void loadStatServices(StatServices *loader)
Definition: LCEcomposite.cc:609
void do_breed_selection_OffSurvival(Patch *patch, unsigned int patchID, unsigned int *cntr)
Definition: LCEcomposite.cc:657
virtual bool resetParameterFromSource(std::string param, SimComponent *cmpt)
Definition: LCEcomposite.h:252
virtual age_t requiredAgeClass()
Definition: LCEcomposite.h:255
void setReproScaledFitness_sum(sex_t SEX, valarray< double > &survival, unsigned int numReproFem, Patch *patch)
Definition: LCEcomposite.cc:865
virtual ~LCE_Breed_Selection()
Definition: LCEcomposite.h:225
LCE_Breed_Selection()
Definition: LCEcomposite.cc:529
virtual age_t removeAgeClass()
Definition: LCEcomposite.h:253
virtual void loadFileServices(FileServices *loader)
Definition: LCEcomposite.h:250
void(LCE_Breed_Selection::* _breed_selection)(Patch *patch, unsigned int patchID, unsigned int *cntr)
Definition: LCEcomposite.h:216
bool setNonSelectedTraitTable()
Builds the vector of traits not under selection.
Definition: LCEcomposite.cc:580
unsigned int _nb_trait
Definition: LCEcomposite.h:218
virtual void execute()
Definition: LCEcomposite.cc:616
Base class for the breeding (and mating) life cycle events.
Definition: LCEbreed.h:44
double getMeanFecundity(unsigned int patch)
Definition: LCEbreed.h:95
The base class of the dispersal LCEs, all events move offspring to the post-dispersal patch container...
Definition: LCEdisperse.h:40
Base class performing (viability) selection on an arbitrary trait.
Definition: LCEselection.h:51
Base class of the Life Cycle Events, declares the LCE interface.
Definition: lifecycleevent.h:73
Second class in the metapopulation design structure, between the Metapop and Individual classes.
Definition: metapop.h:430
unsigned int get_K()
Definition: metapop.h:479
unsigned int size(age_t AGE)
Returns the size of the container of the appropriate age class(es) for both sexes.
Definition: metapop.h:496
unsigned int getID()
Definition: metapop.h:478
bool get_isExtinct()
Definition: metapop.h:484
static double Poisson(double mean)
From the Numerical Recieps.
Definition: Uniform.h:220
static double Uniform()
Generates a random number from [0.0, 1.0[ uniformly distributed.
Definition: Uniform.h:125
Interface to all basic components of a simulation (traits, life cycle events, pop,...
Definition: simcomponent.h:45
The Service class used to manage the StatHandler objects.
Definition: statservices.h:50
sex_t
Sex types, males are always 0 and females 1!!
Definition: types.h:36
@ FEM
Definition: types.h:37
@ MAL
Definition: types.h:37
#define NONE
No age flag.
Definition: types.h:48
unsigned int age_t
Age class flags.
Definition: types.h:46
#define ADULTS
Adults age class flag (breeders).
Definition: types.h:54
#define OFFSPRG
Offspring age class flag.
Definition: types.h:50
@ ADLTx
Definition: types.h:42