enum Compounding { Simple = 0, //!< \f$ 1+rt \f$
Compounded = 1, //!< \f$ (1+r)^t \f$
Continuous = 2, //!< \f$ e^{rt} \f$
SimpleThenCompounded //!< Simple up to the first period then Compounded
};
(1) Would 'Discrete' be a better enum choice instead of 'Compounded', given
that 'Continuous' is also compounded? And 'Simple' could also be 'None'?
(2) Also, what is the use case which prevents you from having a single
discrete compounding case rather than 'SimpleThenCompounded' and
'Compounded'? The code in 'InterestRate::compoundFactor()case
SimpleThenCompounded' seems like it covers thecases I can think of, both
when the first payment is and is not before '1/compoundingFreq' of a year.
thanks,
John McMahon
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users