Struct CommunityParameters¶
- Defined in File parameters.h
Struct Documentation¶
-
struct
CommunityParameters¶ A struct for containing pairs of previous calculations to make sure that aren’t repeated.
Public Functions
-
CommunityParameters()¶ Default constructor.
-
~CommunityParameters()¶ Trivial destructor.
-
CommunityParameters(unsigned long reference_in, long double speciation_rate_in, long double time_in, bool fragment_in, unsigned long metacommunity_reference_in, const ProtractedSpeciationParameters &protracted_params)¶ Constructor for CommunityParameters, for storing a pairs of previous calculations, requiring a speciation rate and a time. Overloaded version with setup routines.
- Parameters
reference_in: the reference to set for this CommunityParameters setspeciation_rate_in: the speciation rate of the previous calculationtime_in: the time of the previous calculationfragment_in: bool of whether fragments were used in the previous calculationmetacommunity_reference_in: the metacommunity reference, or 0 for no metacommunityprotracted_params: protracted speciation parameters to add
-
void
setup(unsigned long reference_in, long double speciation_rate_in, long double time_in, bool fragment_in, unsigned long metacommunity_reference_in, const ProtractedSpeciationParameters &protracted_params) Sets up the CommunityParameters object.
- Parameters
reference_in: the reference to set for this CommunityParameters setspeciation_rate_in: the speciation rate of the previous calculationtime_in: the time of the previous calculationfragment_in: bool of whether fragments were used in the previous calculationmetacommunity_reference_in: the metacommunity reference, or 0 for no metacommunityprotracted_params: protracted speciation parameters to add
-
bool
compare(long double speciation_rate_in, long double time_in, bool fragment_in, unsigned long metacommunity_reference_in, const ProtractedSpeciationParameters &protracted_params)¶ Compare these set of parameters with the input set. If they match, return true, otherwise return false.
- Return
- Parameters
speciation_rate_in: speciation rate to compare with stored community parametertime_in: time to compare with stored community parameterfragment_in: if fragments are being used on this databasemetacommunity_reference_in: metacommunity reference to compare with stored community parameterprotracted_params: the minimum number of generations required for existance before speciationprotracted_params: protracted speciation parameters to add
-
bool
compare(long double speciation_rate_in, long double time_in, unsigned long metacommunity_reference_in, const ProtractedSpeciationParameters &protracted_params)¶ Compare these set of parameters with the input set. If they match, return true, otherwise return false Overloaded version ignoring the fragments parameter.
- Return
- Parameters
speciation_rate_in: speciation rate to compare with stored community parametertime_in: time to compare with stored community parametermetacommunity_reference_in: metacommunity reference to compare with stored community parameterprotracted_params: protracted speciation parameters to add
-
bool
compare(unsigned long reference_in)¶ Checks if the supplied reference is the same in the community parameter.
- Return
- Parameters
reference_in:
-