Package jebl.evolution.coalescent
Class ExponentialGrowth
- java.lang.Object
-
- jebl.evolution.coalescent.ConstantPopulation
-
- jebl.evolution.coalescent.ExponentialGrowth
-
- All Implemented Interfaces:
DemographicFunction
- Direct Known Subclasses:
CataclysmicDemographic,ConstExponential,Expansion,LogisticGrowth
public class ExponentialGrowth extends ConstantPopulation
This class models an exponentially growing (or shrinking) population (Parameters: N0=present-day population size; r=growth rate). This model is nested with the constant-population size model (r=0).- Version:
- $Id: ExponentialGrowth.java 390 2006-07-20 14:33:51Z rambaut $
- Author:
- Alexei Drummond, Andrew Rambaut
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface jebl.evolution.coalescent.DemographicFunction
DemographicFunction.Utils
-
-
Constructor Summary
Constructors Constructor Description ExponentialGrowth()Construct demographic model with default settingsExponentialGrowth(double N0, double r)Construct demographic model with given settings
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description doublegetArgument(int n)Returns the value of the nth argument of this function.intgetArgumentCount()Returns the number of arguments for this function.java.lang.StringgetArgumentName(int n)Returns the name of the nth argument of this function.doublegetDemographic(double t)Gets the value of the demographic function N(t) at time t.doublegetGrowthRate()returns growth rate.doublegetIntensity(double t)Returns value of demographic intensity function at time t (= integral 1/N(x) dx from 0 to t).doublegetInverseIntensity(double x)Returns value of inverse demographic intensity function (returns time, needed for simulation of coalescent intervals).doublegetLowerBound(int n)Returns the lower bound of the nth argument of this function.doublegetUpperBound(int n)Returns the upper bound of the nth argument of this function.voidsetArgument(int n, double value)Sets the value of the nth argument of this function.voidsetDoublingTime(double doublingTime)An alternative parameterization of this model.voidsetGrowthRate(double r)sets growth rate.-
Methods inherited from class jebl.evolution.coalescent.ConstantPopulation
getIntegral, getN0, hasIntegral, setN0
-
-
-
-
Method Detail
-
getGrowthRate
public final double getGrowthRate()
returns growth rate.
-
setGrowthRate
public void setGrowthRate(double r)
sets growth rate.
-
setDoublingTime
public void setDoublingTime(double doublingTime)
An alternative parameterization of this model. This function sets growth rate for a given doubling time.
-
getDemographic
public double getDemographic(double t)
Description copied from interface:DemographicFunctionGets the value of the demographic function N(t) at time t.- Specified by:
getDemographicin interfaceDemographicFunction- Overrides:
getDemographicin classConstantPopulation
-
getIntensity
public double getIntensity(double t)
Description copied from interface:DemographicFunctionReturns value of demographic intensity function at time t (= integral 1/N(x) dx from 0 to t).- Specified by:
getIntensityin interfaceDemographicFunction- Overrides:
getIntensityin classConstantPopulation
-
getInverseIntensity
public double getInverseIntensity(double x)
Description copied from interface:DemographicFunctionReturns value of inverse demographic intensity function (returns time, needed for simulation of coalescent intervals).- Specified by:
getInverseIntensityin interfaceDemographicFunction- Overrides:
getInverseIntensityin classConstantPopulation
-
getArgumentCount
public int getArgumentCount()
Description copied from interface:DemographicFunctionReturns the number of arguments for this function.- Specified by:
getArgumentCountin interfaceDemographicFunction- Overrides:
getArgumentCountin classConstantPopulation
-
getArgumentName
public java.lang.String getArgumentName(int n)
Description copied from interface:DemographicFunctionReturns the name of the nth argument of this function.- Specified by:
getArgumentNamein interfaceDemographicFunction- Overrides:
getArgumentNamein classConstantPopulation
-
getArgument
public double getArgument(int n)
Description copied from interface:DemographicFunctionReturns the value of the nth argument of this function.- Specified by:
getArgumentin interfaceDemographicFunction- Overrides:
getArgumentin classConstantPopulation
-
setArgument
public void setArgument(int n, double value)Description copied from interface:DemographicFunctionSets the value of the nth argument of this function.- Specified by:
setArgumentin interfaceDemographicFunction- Overrides:
setArgumentin classConstantPopulation
-
getLowerBound
public double getLowerBound(int n)
Description copied from interface:DemographicFunctionReturns the lower bound of the nth argument of this function.- Specified by:
getLowerBoundin interfaceDemographicFunction- Overrides:
getLowerBoundin classConstantPopulation
-
getUpperBound
public double getUpperBound(int n)
Description copied from interface:DemographicFunctionReturns the upper bound of the nth argument of this function.- Specified by:
getUpperBoundin interfaceDemographicFunction- Overrides:
getUpperBoundin classConstantPopulation
-
-