commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gilles Sadowski <gil...@harfang.homelinux.org>
Subject Re: svn commit: r980032 - in /commons/proper/math/trunk/src: main/java/org/apache/commons/math/ main/java/org/apache/commons/math/optimization/univariate/ test/java/org/apache/commons/math/optimization/ test/java/org/apache/commons/math/optimization/univar...
Date Wed, 28 Jul 2010 13:02:09 GMT
> [...]
> > -    private double localMin(UnivariateRealFunction f,
> > -                            GoalType goalType,
> > +    private double localMin(boolean isMinim,
> >                              double lo, double mid, double hi,
> >                              double eps, double t)
> 
> Perhaps we should change this method name to localExtremum ? It seems we
> forgot to do that earlier despite the method was able to either minimize
> or maximize a function.

Could be. "localMin" is the name used in Brent's book. It could be left as a
reminder of that. Or changed. Or removed altogether since "doOptimize()"
could in fact contain the whole body of "localMin".

> [...]
> > -        assertTrue(minimizer.getEvaluations() > 1500);
> > -        assertTrue(minimizer.getEvaluations() < 1700);
> > +        assertTrue(minimizer.getEvaluations() > 150);
> > +        assertTrue(minimizer.getEvaluations() < 250);
> 
> Wow ! These are impressive improvements.
> Many thanks for these.

This should not count as an improvement; it's amazing how bugs can make
things much worse than they should ;-}


Gilles

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Mime
View raw message