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 settings
`ExponentialGrowth(double N0, double r)`
Construct demographic model with given settings

## Method Summary

Modifier and Type
Method
Description
`double`
`getArgument(int n)`
Returns the value of the nth argument of this function.
`int`
`getArgumentCount()`
Returns the number of arguments for this function.
`String`
`getArgumentName(int n)`
Returns the name of the nth argument of this function.
`double`
`getDemographic(double t)`
Gets the value of the demographic function N(t) at time t.
`final double`
`getGrowthRate()`
returns growth rate.
`double`
`getIntensity(double t)`
Returns value of demographic intensity function at time t (= integral 1/N(x) dx from 0 to t).
`double`
`getInverseIntensity(double x)`
Returns value of inverse demographic intensity function (returns time, needed for simulation of coalescent intervals).
`double`
`getLowerBound(int n)`
Returns the lower bound of the nth argument of this function.
`double`
`getUpperBound(int n)`
Returns the upper bound of the nth argument of this function.
`void`
`setArgument(int n, double value)`
Sets the value of the nth argument of this function.
`void`
`setDoublingTime(double doublingTime)`
An alternative parameterization of this model.
`void`
`setGrowthRate(double r)`
sets growth rate.

### Methods inherited from class jebl.evolution.coalescent.ConstantPopulation

`getIntegral, getN0, hasIntegral, setN0`

### Methods inherited from class java.lang.Object

`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Constructor Details

### ExponentialGrowth

public ExponentialGrowth()
Construct demographic model with default settings

### ExponentialGrowth

public ExponentialGrowth(double N0, double r)
Construct demographic model with given settings

## Method Details

### 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: `DemographicFunction`
Gets the value of the demographic function N(t) at time t.

Specified by:
  `getDemographic` in interface `DemographicFunction`
Overrides:
  `getDemographic` in class `ConstantPopulation`

### getIntensity

public double getIntensity(double t)
Description copied from interface: `DemographicFunction`
Returns value of demographic intensity function at time t (= integral 1/N(x) dx from 0 to t).

Specified by:
  `getIntensity` in interface `DemographicFunction`
Overrides:
  `getIntensity` in class `ConstantPopulation`

### getInverseIntensity

public double getInverseIntensity(double x)
Description copied from interface: `DemographicFunction`
Returns value of inverse demographic intensity function (returns time, needed for simulation of coalescent intervals).

Specified by:
  `getInverseIntensity` in interface `DemographicFunction`
Overrides:
  `getInverseIntensity` in class `ConstantPopulation`

### getArgumentCount

public int getArgumentCount()
Description copied from interface: `DemographicFunction`
Returns the number of arguments for this function.

Specified by:
  `getArgumentCount` in interface `DemographicFunction`
Overrides:
  `getArgumentCount` in class `ConstantPopulation`

### getArgumentName

public String getArgumentName(int n)
Description copied from interface: `DemographicFunction`
Returns the name of the nth argument of this function.

Specified by:
  `getArgumentName` in interface `DemographicFunction`
Overrides:
  `getArgumentName` in class `ConstantPopulation`

### getArgument

public double getArgument(int n)
Description copied from interface: `DemographicFunction`
Returns the value of the nth argument of this function.

Specified by:
  `getArgument` in interface `DemographicFunction`
Overrides:
  `getArgument` in class `ConstantPopulation`

### setArgument

public void setArgument(int n, double value)
Description copied from interface: `DemographicFunction`
Sets the value of the nth argument of this function.

Specified by:
  `setArgument` in interface `DemographicFunction`
Overrides:
  `setArgument` in class `ConstantPopulation`

### getLowerBound

public double getLowerBound(int n)
Description copied from interface: `DemographicFunction`
Returns the lower bound of the nth argument of this function.

Specified by:
  `getLowerBound` in interface `DemographicFunction`
Overrides:
  `getLowerBound` in class `ConstantPopulation`

### getUpperBound

public double getUpperBound(int n)
Description copied from interface: `DemographicFunction`
Returns the upper bound of the nth argument of this function.

Specified by:
  `getUpperBound` in interface `DemographicFunction`
Overrides:
  `getUpperBound` in class `ConstantPopulation`