|
QuantLib: a free/open-source library for quantitative finance
Reference manual - version 1.40
|
Black delta calculator class. More...
#include <ql/pricingengines/blackdeltacalculator.hpp>
Constructors | |
| BlackDeltaCalculator (Option::Type ot, DeltaVolQuote::DeltaType dt, Real spot, DiscountFactor dDiscount, DiscountFactor fDiscount, Real stdDev) | |
| Constructs a BlackDeltaCalculator object This class provides methods to calculate option delta and strike values using the Black-Scholes formula, supporting various FX delta conventions (spot, forward, premium-adjusted, etc.). It is designed for efficient repeated calculations across different strikes, which is useful in volatility smile construction and calibration routines. | |
| Real | deltaFromStrike (Real strike) const |
| Computes the option delta for a given strike. | |
| Real | strikeFromDelta (Real delta) const |
| Computes the strike corresponding to a given delta. | |
| Real | atmStrike (DeltaVolQuote::AtmType atmT) const |
| Calculates the at-the-money (ATM) strike for the given ATM convention. | |
| void | setDeltaType (DeltaVolQuote::DeltaType dt) |
| Sets the delta calculation convention. | |
| void | setOptionType (Option::Type ot) |
| Sets the option type (call or put). | |
| Real | cumD1 (Real strike) const |
| Real | cumD2 (Real strike) const |
| Real | nD1 (Real strike) const |
| Real | nD2 (Real strike) const |
Black delta calculator class.
Class includes many operations needed for different applications in FX markets, which has special quotation mechanisms, since every price can be expressed in both numeraires.
| BlackDeltaCalculator | ( | Option::Type | ot, |
| DeltaVolQuote::DeltaType | dt, | ||
| Real | spot, | ||
| DiscountFactor | dDiscount, | ||
| DiscountFactor | fDiscount, | ||
| Real | stdDev ) |
Constructs a BlackDeltaCalculator object This class provides methods to calculate option delta and strike values using the Black-Scholes formula, supporting various FX delta conventions (spot, forward, premium-adjusted, etc.). It is designed for efficient repeated calculations across different strikes, which is useful in volatility smile construction and calibration routines.
| ot | Option type (call or put) |
| dt | Delta type (spot, forward, premium-adjusted, etc.) |
| spot | Spot FX rate |
| dDiscount | Domestic discount factor |
| fDiscount | Foreign discount factor |
| stdDev | Standard deviation of the underlying |
Computes the option delta for a given strike.
Calculates the delta of an option using the Black-Scholes formula, according to the delta convention specified at construction (spot, forward, premium-adjusted, etc.).
| strike | The option strike price. |
Computes the strike corresponding to a given delta.
Inverts the Black-Scholes formula to find the strike that yields the specified delta, according to the delta convention set at construction. Used for constructing volatility smiles and for quoting FX options by delta.
| delta | The target option delta (under the chosen convention). |
| Real atmStrike | ( | DeltaVolQuote::AtmType | atmT | ) | const |
Calculates the at-the-money (ATM) strike for the given ATM convention.
Computes the strike price that corresponds to "at-the-money" under different conventions commonly used in FX markets. This method does not require an explicit strike input as it determines the ATM level based on the specified convention.
| atmT | The ATM convention to use:
|
| void setDeltaType | ( | DeltaVolQuote::DeltaType | dt | ) |
Sets the delta calculation convention.
| dt | The new delta type convention: |
| void setOptionType | ( | Option::Type | ot | ) |
Sets the option type (call or put).
| ot | The option type |