public static double calculateAnalyticalLogLikelihood(IntervalList intervals){
  if (!intervals.isCoalescentOnly()) {
    throw new IllegalArgumentException("Can only calculate analytical likelihood for pure coalescent intervals");
  }
  final double lambda=getLambda(intervals);
  final int n=intervals.getSampleCount();
  return (1 - n) * Math.log(lambda);
}

public static double calculateAnalyticalLogLikelihood ( IntervalList intervals ) { if ( ! intervals . isCoalescentOnly ( ) ) { throw new IllegalArgumentException ( "Can only calculate analytical likelihood for pure coalescent intervals" ) ; } final double lambda = getLambda ( intervals ) ; final int n = intervals . getSampleCount ( ) ; return ( 1 - n ) * Math . log ( lambda ) ; }
calculates the log likelihood of this set of coalescent intervals , using an analytical integration over theta .
