From 0755c5d8e8fc7d401db8d277ca9034a1329979f7 Mon Sep 17 00:00:00 2001 From: Phil Steitz Date: Sat, 5 Nov 2011 22:27:06 +0000 Subject: [PATCH] Javadoc improvements. git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1198101 13f79535-47bb-0310-9956-ffa450edef68 --- .../solvers/BaseUnivariateRealSolver.java | 24 +++++++++++++++++-- 1 file changed, 22 insertions(+), 2 deletions(-) diff --git a/src/main/java/org/apache/commons/math/analysis/solvers/BaseUnivariateRealSolver.java b/src/main/java/org/apache/commons/math/analysis/solvers/BaseUnivariateRealSolver.java index c305a585a..e96a861bb 100644 --- a/src/main/java/org/apache/commons/math/analysis/solvers/BaseUnivariateRealSolver.java +++ b/src/main/java/org/apache/commons/math/analysis/solvers/BaseUnivariateRealSolver.java @@ -37,9 +37,9 @@ import org.apache.commons.math.analysis.UnivariateRealFunction; */ public interface BaseUnivariateRealSolver { /** - * Get the maximal number of function evaluations. + * Get the maximum number of function evaluations. * - * @return the maximal number of function evaluations. + * @return the maximum number of function evaluations. */ int getMaxEvaluations(); @@ -54,14 +54,34 @@ public interface BaseUnivariateRealSolver { int getEvaluations(); /** + * Get the absolute accuracy of the solver. Solutions returned by the + * solver should be accurate to this tolerance, i.e., if ε is the + * absolute accuracy of the solver and {@code v} is a value returned by + * one of the {@code solve} methods, then a root of the function should + * exist somewhere in the interval ({@code v} - ε, {@code v} + ε). + * * @return the absolute accuracy. */ double getAbsoluteAccuracy(); + /** + * Get the relative accuracy of the solver. The contract for relative + * accuracy is the same as {@link #getAbsoluteAccuracy()}, but using + * relative, rather than absolute error. If ρ is the relative accuracy + * configured for a solver and {@code v} is a value returned, then a root + * of the function should exist somewhere in the interval + * ({@code v} - ρ {@code v}, {@code v} + ρ {@code v}). + * * @return the relative accuracy. */ double getRelativeAccuracy(); + /** + * Get the function value accuracy of the solver. If {@code v} is + * a value returned by the solver for a function {@code f}, + * then by contract, {@code |f(v)|} should be less than or equal to + * the function value accuracy configured for the solver. + * * @return the function value accuracy. */ double getFunctionValueAccuracy();