Dear list,
A quick question regarding
https://github.com/lballabio/quantlib/blob/master/QuantLib/ql/time/schedule.cpp:
Lines 137-141 contain the following code:
QL_REQUIRE(firstDate_ > effectiveDate &&
firstDate_ < terminationDate,
"first date (" << firstDate_ <<
") out of effective-termination date range [" <<
effectiveDate << ", " << terminationDate << ")");
However, it seems that the condition should be firstDate_ >
effectiveDate && firstDate_ <= terminationDate. Otherwise it is not
possible to have a first (and only) coupon fall on maturity. The use of
")" and "]" in the error message also seems to suggest that this should
be the case, when compared to lines 165-169, where a similar check is
performed for nextToLastDate_.
Is there a reason why this condition is exclusive rather than inclusive
wrt terminationDate?
Thanks,
Pascal
------------------------------------------------------------------------------
Don't Limit Your Business. Reach for the Cloud.
GigeNET's Cloud Solutions provide you with the tools and support that
you need to offload your IT needs and focus on growing your business.
Configured For All Businesses. Start Your Cloud Today.
https://www.gigenetcloud.com/
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users
<http://leanpub.com/implementingquantlib/>
<http://implementingquantlib.com>
<http://twitter.com/lballabio>
| Free forum by Nabble | Edit this page |