jebl.evolution.coalescent
Class CoalescentIntervalGenerator

java.lang.Object
  extended by jebl.evolution.coalescent.CoalescentIntervalGenerator
All Implemented Interfaces:
IntervalGenerator

public class CoalescentIntervalGenerator
extends Object
implements IntervalGenerator

This is a class that draws coalescent intervals under the given demographic function. If the demographic function class has an analytical function for the integral of 1/N(t) then this is used otherwise a numerical integrator is used. To generate a tree using this class, see the TreeSimulator class in jebl.evolution.trees. Much of this class was derived from C++ code provided by Oliver Pybus.

Author:
Andrew Rambaut, Oliver Pybus

Field Summary
protected  DemographicFunction demographicFunction
           
 
Constructor Summary
CoalescentIntervalGenerator(DemographicFunction demographicFunction)
           
 
Method Summary
 double getInterval(double criticalValue, int lineageCount, double currentHeight)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

demographicFunction

protected DemographicFunction demographicFunction
Constructor Detail

CoalescentIntervalGenerator

public CoalescentIntervalGenerator(DemographicFunction demographicFunction)
Method Detail

getInterval

public double getInterval(double criticalValue,
                          int lineageCount,
                          double currentHeight)
Specified by:
getInterval in interface IntervalGenerator