Finance - Maple Programming Help

Online Help

All Products    Maple    MapleSim


Home : Support : Online Help : Mathematics : Finance : Financial Instruments : Finance/BlackPrice

Finance

  

BlackPrice

  

calculate the price of an interest rate instrument using the Black model

 

Calling Sequence

Parameters

Options

Description

Examples

Compatibility

Calling Sequence

BlackPrice(instrument, discountrate, volatility)

Parameters

instrument

-

cap, floor, collar or swaption; financial instrument

discountrate

-

non-negative constant or a yield term structure; discount rate

volatility

-

non-negative constant; volatility

opts

-

equations of the form option = value where option is one of referencedate or daycounter; specify options for the BlackPrice command

Options

• 

daycounter =  a string containing a date specification in a format recognized by ParseDate or a date data structure -- This option specifies a day counter or day counting convention.

• 

referencedate =  a string containing a date specification in a format recognized by ParseDate or a date data structure -- This option specifies the reference date, that is, the date when the discount factor is 1. By default this is set to the global evaluation date.

Description

• 

The BlackPrice command computes the price of an interest rate instrument (such as Cap, Floor, Collar or InterestRateSwap) using the Black model with the specified discount rate and volatility.

Examples

withFinance:

Set the global evaluation date. This date is taken as the reference date for all yield curves and benchmark rates unless another date is specified explicitly.

SetEvaluationDateNovember 17, 2006:

EvaluationDate

November 17, 2006

(1)

The nominal amount is 100.

nominalamt100

nominalamt:=100

(2)

Create a 6-month EURIBOR benchmark rate with a forecasted rate of 5%. No history is available for this rate.

benchmarkBenchmarkRate6,Months,EURIBOR,0.05

benchmark:=moduleend module

(3)

Construct a discount interest rate curve.

discount_curveForwardCurve0.05,'daycounter'=Actual360

discount_curve:=moduleend module

(4)

Construct floating-leg payments.

start_dateAdvanceDate2,Days

start_date:=November 19, 2006

(5)

end_dateAdvanceDatestart_date,20,Years,'convention'=ModifiedFollowing

end_date:=November 19, 2026

(6)

coupon_datesseqAdvanceDatestart_date,6i,Months,i=0..40:

floating_legseqParCouponnominalamt,discount_curve,coupon_datesi,coupon_datesi+1,i=1..40:

Construct an interest rate cap with a fixed cap rate of 7% for all payments in the floating leg.

ir_capCapfloating_leg,0.07

ir_cap:=moduleend module

(7)

ir_floorFloorfloating_leg,0.03

ir_floor:=moduleend module

(8)

ir_collarCollarfloating_leg,0.07,0.03

ir_collar:=moduleend module

(9)

Price these instruments using the Black model with a discount rate of 5% and a volatility of 20%, and verify that the price of the cap is equal to the sum of the prices of the other two instruments.

cap_priceBlackPriceir_cap,0.05,0.2

cap_price:=6.832847321

(10)

floor_priceBlackPriceir_floor,0.05,0.2

floor_price:=2.642595692

(11)

collar_priceBlackPriceir_collar,0.05,0.2

collar_price:=4.190251628

(12)

cap_price=floor_price+collar_price

6.832847321=6.832847320

(13)

Compatibility

• 

The Finance[BlackPrice] command was introduced in Maple 15.

• 

For more information on Maple 15 changes, see Updates in Maple 15.

See Also

Finance[CompoundFactor]

Finance[DiscountFactor]

Finance[FixedRateCoupon]

Finance[InArrearIndexedCoupon]

Finance[ParCoupon]

Finance[SimpleCashFlow]

Finance[UpFrontIndexedCoupon]

Finance[ZeroCurve]

 


Download Help Document

Was this information helpful?



Please add your Comment (Optional)
E-mail Address (Optional)
What is ? This question helps us to combat spam