DiscretizedOption question

Posted by JURAJ HUSKA on
URL: http://quantlib.414.s1.nabble.com/DiscretizedOption-question-tp5544.html

Hello all,

this is a question for QuantLib experts.
Why is there a warning "it is advised that derived classes take care of creating and initializing themselves an instance of the underlying" in DiscretizedOption class documentation?

I am asking because it may help me resolve an issue with my code.
I created an object of similar structure (to DiscretizedOption) , call it "bondoptioncalculator", and it seems to run OK in debug mode but when I compile it to a dll and run it from another application it seems to be blowing up "randomly". Let's say I run my bondoptioncalculator on a set of 100 bonds, it may happen that the application throws an error on 50th bond the first time around and everything else goes through smoothly and the next time around it blows up on 20 th bond, etc. It seems something stays static in the dll (or some objects don't get created/destroyed?) and influences next runs of the code.

Juraj


-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users