Posted by
Ferdinando M. Ametrano-3 on
URL: http://quantlib.414.s1.nabble.com/Bonds-sample-tp12365p12370.html
Hi Nicolai
> what is the reasoning behind the fact
> that one has to create a schedule (for coupons) and provide it to the bond
> constructor, instead of providing the necessary information to the bond
> constructor and then have it construct the needed schedule?
I would reverse the question and ask what would be the reason to have
multiple input parameters used for Schedule construction instead of
just passing a Schedule, that is a single parameter.
Besides it is not rare the case in which the schedule used for the
bond might have been originated from a swap, or viceversa
> Furthermore when you need the bond yield [...] the need to provide the
> Frequency parameter troubles me, because that frequency was allready
> provided when the coupon schedule was created.
I don't have access to the code right now, but if I remember right the
input frequency is used in order to calculate the actual coupon
payment from the coupon rate, and it might be different from the
frequency used to calculate the yield, e.g. when you want to compare
the yield of 2 bonds with different coupon rate frequency and/or
schedule
hope it helps
ciao -- Nando
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev