Posted by
Dimathematician on
URL: http://quantlib.414.s1.nabble.com/Optimizer-Discussion-tp13001.html
1: CostFunction::values()
As far as I see, the values function is not needed anywhere, except in the Levenberg Marquardt
optimizer. Can we change it from a pure virtual function to a virtual which by default returns
a one dimensional array with values(x)? It is confusing and takes a while to understand why
-and if- it is needed at all. For example, if I understand the code correctly, if you optimize with Simplex,
you can set values to any value (e.g.1000). In my opinion it is an overkill to make it pure virtual just in case
somebody uses LM. I'd rather suggest to test in LM whether the function has been overwritten.
2. EndCriteria:
Most of the functions do not use all of the passed values. I haven't found one which uses the gradient
norm. Please correct me if I'm wrong. Most of them use max iterations anf function value epsilon.
I think it might be better to make this clean such that the user doesn't have a wrong impression, that
actually everything is checked. I haven't found one optimizer which checks min stationary value.
For example, in Simplex: endCriteria.checkStationaryPoint(0.0, 0.0,
maxStationaryStateIterations_, ecType);
does that, but maxStationaryStateIterations_ is not increased anywhere during the optimization.
All points above subject to non-blindness of author of this mail :)
------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.
http://p.sf.net/sfu/bobj-july_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev