Note: This page has been translated by MathWorks. Click here to see

To view all translated materials including this page, select Country from the country navigator on the bottom of this page.

To view all translated materials including this page, select Country from the country navigator on the bottom of this page.

Calculate price and sensitivities of European or American spread options using finite difference method

`PriceSens = spreadsensbyfd(RateSpec,StockSpec1,StockSpec2,Settle,Maturity,OptSpec,Strike,Corr)`

`PriceSens = spreadsensbyfd(___,Name,Value)`

```
[PriceSens,PriceGrid,AssetPrice1,AssetPrice2,Times]
= spreadsensbyfd(RateSpec,StockSpec1,StockSpec2,Settle,Maturity,OptSpec,Strike,Corr)
```

```
[PriceSens,PriceGrid,AssetPrice1,AssetPrice2,Times]
= spreadsensbyfd(___,Name,Value)
```

returns the price and sensitivities of European or American call or put spread options
using the Alternate Direction Implicit (ADI) finite difference method. The spread is
between the asset defined in `PriceSens`

= spreadsensbyfd(`RateSpec`

,`StockSpec1`

,`StockSpec2`

,`Settle`

,`Maturity`

,`OptSpec`

,`Strike`

,`Corr`

)`StockSpec1`

minus the asset defined in
`StockSpec2`

.

adds optional name-value pair arguments.`PriceSens`

= spreadsensbyfd(___,`Name,Value`

)

`[`

returns the `PriceSens`

,`PriceGrid`

,`AssetPrice1`

,`AssetPrice2`

,`Times`

]
= spreadsensbyfd(`RateSpec`

,`StockSpec1`

,`StockSpec2`

,`Settle`

,`Maturity`

,`OptSpec`

,`Strike`

,`Corr`

)`PriceSens`

, `PriceGrid`

,
`AssetPrice1`

, `AssetPrice2`

, and
`Times`

for European or American call or put spread options using the
Alternate Direction Implicit (ADI) finite difference method. The spread is between the
asset defined in `StockSpec1`

minus the asset defined in
`StockSpec2`

.

`[`

returns the `PriceSens`

,`PriceGrid`

,`AssetPrice1`

,`AssetPrice2`

,`Times`

]
= spreadsensbyfd(___,`Name,Value`

)`PriceSens`

, `PriceGrid`

,
`AssetPrice1`

, `AssetPrice2`

, and
`Times`

and adds optional name-value pair arguments.

[1] Carmona, R., Durrleman, V. “Pricing and Hedging Spread Options.”
*SIAM Review.* Vol. 45, No. 4, pp. 627–685, Society for Industrial and
Applied Mathematics, 2003.

[2] Villeneuve, S., Zanette, A. “Parabolic ADI Methods for Pricing American
Options on Two Stocks.” *Mathematics of Operations Research.* Vol.
27, No. 1, pp. 121–149, INFORMS, 2002.

[3] Ikonen, S., Toivanen, J. *Efficient Numerical Methods for Pricing American
Options Under Stochastic Volatility.* Wiley InterScience, 2007.