Re: Optimizer Discussion

Posted by Dimathematician on
URL: http://quantlib.414.s1.nabble.com/Optimizer-Discussion-tp13001p13003.html

Why exception? It has its use when LM is used. Or do you
want to make it virtual and throw an exception if its not
overwritten?

Had a look at the optimizers. Just a few End-Criterias
are really checked. 

2009/9/11 Luigi Ballabio <[hidden email]>
On Sat, 2009-09-05 at 13:07 +0200, Dima wrote:
> 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)?

Possibly, but I'd rather change it to a function which by default throws
an exception.  Also because it wouldn't be easy for LM to check that
it's been overridden.

> 2. EndCriteria:
>
> Most of the functions do not use all of the passed values. [...]
> 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.

Yes, we should document that.  Have you looked at the solvers already?
Do you have a list of what's checked in what solver?

Later,
       Luigi


--

Hanlon's Razor:
Never attribute to malice that which is adequately explained
by stupidity.




------------------------------------------------------------------------------
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