diff --git a/commons-math-legacy/src/main/java/org/apache/commons/math4/legacy/analysis/RealFieldUnivariateFunction.java b/commons-math-legacy/src/main/java/org/apache/commons/math4/legacy/analysis/RealFieldUnivariateFunction.java index 5c0a9a390..1f9a36692 100644 --- a/commons-math-legacy/src/main/java/org/apache/commons/math4/legacy/analysis/RealFieldUnivariateFunction.java +++ b/commons-math-legacy/src/main/java/org/apache/commons/math4/legacy/analysis/RealFieldUnivariateFunction.java @@ -34,16 +34,19 @@ import org.apache.commons.math4.legacy.core.RealFieldElement; * // The x value that caused the problem. * private final SomeFieldType x; * - * public LocalException(SomeFieldType x) { + * LocalException(SomeFieldType x) { * this.x = x; * } * - * public double getX() { + * SomeFieldType getX() { * return x; * } * } * * private static class MyFunction implements FieldUnivariateFunction<SomeFieldType> { + * + * // ... function set-up + * * public SomeFieldType value(SomeFieldType x) { * SomeFieldType y = hugeFormula(x); * if (somethingBadHappens) {