Difference between revisions of "Programming/Kdb/Labs/Option pricing"
| Line 6: | Line 6: | ||
Here | Here | ||
* <math>t</math> is a time in years; we generally use <math>t = 0</math> as now; | * <math>t</math> is a time in years; we generally use <math>t = 0</math> as now; | ||
* <math>V(S, t)</math> is the | * <math>V(S, t)</math> is the value of the option; | ||
* <math>S(t)</math> is the price of the underlying asset at time <math>t</math>; | * <math>S(t)</math> is the price of the underlying asset at time <math>t</math>; | ||
* <math>\sigma</math> is the volatility — the standard deviation of the asset's returns; | * <math>\sigma</math> is the volatility — the standard deviation of the asset's returns; | ||
* <math>r</math> is the annualized risk-free interest rate, continuously compounded; | * <math>r</math> is the annualized risk-free interest rate, continuously compounded; | ||
* <math>q</math> is the annualized (continuous) dividend yield. | * <math>q</math> is the annualized (continuous) dividend yield. | ||
The solution of this equation depends on the '''payoff''' of the option — the terminal condition. In particular, if at the time of expiration, <math>T</math>, the payoff is given by <math>V(S, T) = \max\{S - K, 0\}</math>, in other words, the option is a '''European call option''', then the value of the option at time <math>t</math> is given by the '''Black-Scholes formula''' | |||
Revision as of 22:26, 17 June 2021
Recall the celebrated Black-Scholes equation
Here
- Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle t} is a time in years; we generally use Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle t = 0} as now;
- Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle V(S, t)} is the value of the option;
- Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle S(t)} is the price of the underlying asset at time ;
- is the volatility — the standard deviation of the asset's returns;
- Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle r} is the annualized risk-free interest rate, continuously compounded;
- Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle q} is the annualized (continuous) dividend yield.
The solution of this equation depends on the payoff of the option — the terminal condition. In particular, if at the time of expiration, Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle T} , the payoff is given by Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle V(S, T) = \max\{S - K, 0\}} , in other words, the option is a European call option, then the value of the option at time Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle t} is given by the Black-Scholes formula