de.torstennahm.integrate.error
Class RoundingErrorEstimator

java.lang.Object
  extended by de.torstennahm.integrate.error.RoundingErrorEstimator
All Implemented Interfaces:
ErrorEstimator

public class RoundingErrorEstimator
extends java.lang.Object
implements ErrorEstimator

Estimates the error caused by floating point rounding errors. The estimator assumes that all calculations are done with double floating point accuracy.

Author:
Torsten Nahm

Constructor Summary
RoundingErrorEstimator()
           
 
Method Summary
 double getEstimate()
          Returns the estimate of the integration error based on the log.
 void log(long pointsEvaluated, double currentResult)
          Logs the current integration value.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RoundingErrorEstimator

public RoundingErrorEstimator()
Method Detail

log

public void log(long pointsEvaluated,
                double currentResult)
Description copied from interface: ErrorEstimator
Logs the current integration value.

Specified by:
log in interface ErrorEstimator
Parameters:
pointsEvaluated - number of function evaluations for this integral value
currentResult - current integral value

getEstimate

public double getEstimate()
Description copied from interface: ErrorEstimator
Returns the estimate of the integration error based on the log.

Specified by:
getEstimate in interface ErrorEstimator
Returns:
estimate of the integration error