We evaluate the Par Yield of a Treasury bond which pays annual or semi-annual coupons.
public double ParYieldWithExplicitTime( doubleprincipalSum, doublematurity, boolannualOrSemi, doublematurityZero, double[]timeToCoupons, double[]zeroCurveOnCouponPaymentDates );
Parameters
principalSum
The principal sum (also known as the face value) of the bond.
maturity
The maturity of the bond in years expressed in decimal format.
annualOrSemi
When the coupon is paid annually then this parameter is true and if the coupon is paid semi-annually then it is false.
maturityZero
The zero rate for the maturity of the bond under consideration.
timeToCoupons
An array where the first term is the number of years expressed as a decimal until the first coupon payment is made, and the second term is the number of years until the second coupon payment is made and so on.
zeroCurveOnCouponPaymentDates
An array where the first term is the Treasury zero interest rate of maturity equal to the time until the first coupon payment, and the second term is the Treasury zero interest rate of maturity equal to the time until the second coupon payment, and so on.
Remarks
Recall, that the Par yield for a given maturity is the yield to causes the bonds price to equal
the principle sum (or face value) repaid at maturity.
The Treasury bonds Par yield is evaluated using the zero term structure of the corresponding
Treasury zero curve. In order to apply this approach the zero curve will need to be evaluated
on maturities which correspond to the coupon payment dates. For example, if we consider a two
year bond which pays a semiannual coupon then the Treasury zero rates will need to be known for
the maturities 0.5, 1, 1.5 and 2 years.