|
From: thusi <ts...@ho...> - 2009-01-03 09:24:38
|
Hi
Could some one please tell me the purpose of the ------for loop ------------
in the code below.
The code is in the test-suite of quantlib. The cpp file is
pathgenerator.cpp.
------------------------------------------
for (i=0; i<100; i++)
generator.next();
sample_type sample = generator.next();
Real calculated = sample.value.back();
Real error = std::fabs(calculated-expected);
--------------------------------------------
What I don't understand is why does it generate hundred samples, and then do
the calculation of the variable ---Calculated---. Does it do some kind of
averaging of all these paths?
Thanks a lot.
Thusi
--
View this message in context: http://www.nabble.com/PathGenerator%3A-Question-relating-to-PathGenerator-Test-Case-tp21263290p21263290.html
Sent from the quantlib-dev mailing list archive at Nabble.com.
|