
ARTWare®
Exotic Options:
with
Maxima® and
Mathematica®
Illustration
Available at the
ARTShop
Tell a Friend
A Maxima® or
Mathematica® Notebook
looks like a document, but its "live". As with most "symbolic
manipulators" (see here), equations can be entered, and the system "understands" the
equation in symbolic terms. The symbolic equations can be used for
further symbolic analysis, or to obtain more traditional numerical results.
The
image to the right shows the basic Exotic Option (XO) Mathematica® Notebook with the major Chapter
headings. The Notebook is composed of "cells". These are not
quite like the cells in a spreadsheet, but they do hold "executable"
(or "evaluatable") expressions. Here, the cells are "collapsed" and
only show the heading lines.
click to enlarge
By
double clicking the right "cell boundary" of the Black-Scholes Chapter, the
cells for that Chapter are expanded. Here, several
Sections/Subsections are visible, each with collapsed/nested cells of its
own.
click to enlarge
Expanding
the Black-Scholes Pricing Section shows that it has cells with text, and
cells with formulas. The cell marked "In[42]=" is a cell which
sets the values of the variables
p, k, r, d, v,
and
t
to ".". This simply "clears" their contents. Next, the
formula BSOpt[p,k,v,r,d,t]
is evaluated (just put the cursor in the cell, and press Shift + Enter).
Since its input variables have been "cleared", it returns the "core equation" that
it represents in the cell marked "Out[46]=". Importantly, it "really understands" this as a symbolic
mathematical formula, rather than some collection of letters. For
example, one may now use Mathematica® to analytically differentiate
this formula to obtain, for example, the option's Vega, Theta, etc.
Of
course, if the variable are provided values, then the evaluation will return
the "answer" of the calculation in numerical terms. The image to the
right shows the evaluation of 105 strike call option with the stated
parameters: the option's premium is returned as
4.9823.
click to enlarge
Once
it is possible to have symbolic representation, it is possible to evaluate
the custom formulas in more complex ways. One very useful feature is
the graphing of securities and derivatives value and risk formulas directly
to provide "scenario analysis".
The image to the right shows the call option formula from above evaluated
for a range of underlying prices from inception to expiration.
A
slightly more sophisticated result is possible by using differentiation
to produce graphs for the key option risks (i.e. the "Greeks").
Each risk is generated in terms
of important market parameters, as shown here for a short call
option position.
click to enlarge
It
is a straightforward matter to create formulas for many different types of
options/contracts. Here, several Greeks for a Knock-Out-Call option
are graphed in terms of market parameters, as was done with the vanilla call
option above. The Barrier option's risk profiles are considerably more
complex, and have some interesting properties that are immediately evident
from this type of "macro risk/scenario analysis", but would be near impossible to see
with strict numerical analysis. For example, the Theta profile clearly
shows that the position is "simultaneously long and short vol", depending on
the underlying market. Thus, under some conditions Theta
will be a cost, while under other conditions it will be a revenue.
Another important "macro risk" observation is that that Vega has a complex
structure, but for the most part it is only "material" for a narrow range of
volatilities. This occurs since low vol will have the vanilla option
likely expiry worthless, while high vol will likely knock-out the call, and so
again expires worthless. However, "in-between" those vols Vega hedging will be very tricky as its sensitivity various greatly.
This
type of easy formulaic analysis can also be used for model verification or
even "model arbitrage" analysis. The image to the right shows
comparative valuation profiles for an Asian call option based on two
different Asian option valuation formulas, and compared to the vanilla
option case for completeness.
click to enlarge
Comparative
analysis can also be used to test synthetic replication strategies, and
their effectiveness. The image to the right shows the pay-out profiles
for a Chooser option and two vanilla options (a call and put forming a
"static replicating strangle"). The graph suggests quite good agreement, and
implies that the strangle is expected to be a reasonably good (profile
match) hedge for this Chooser option.

Just as important as showing that a
replication/hedge strategy works, is knowing when a hedge strategy does not
work. The image to the right shows a portfolio composed of long a
spread option, and short the underlying call and put options. Notice
that this was created symbolically by "plotting the portfolio" (i.e. the
plotting is for "-1 Call - 1 Put + 1 SpreadOption ]").
Notice that the hedge is excellent in 2 "quadrants" (i.e. the P&L
if flat), but very poor in the
other 2 quadrants (where it is loosing increasing amounts of money for
varying market conditions).
This immediately shows the weakness of this strategy (namely that an option
on a portfolio is not the same as a portfolio of options), and it also shows
under which market conditions this strategy will be unacceptable.
This type of "symbolic"
implementation of securities and derivatives valuation, risk, and position
analysis is not meant to replace the standard day-to-day "ticketing"
or "position keeping" machinery. Rather, it is a useful tool to
provide fast analysis of models, structures, hedging strategies, and related
matters. It is also an excellent tool for creating presentations to
clients, shareholders, regulators, or for training purposes.
Currently there are two
Mathematica® Notebooks and a
Maxima® package
available:
TG2 Exotic Options "Complementary" Edition. This
is an abridged "complementary" version (also available as part of
ARTSchool and
TG2Books)
ARTWare Symbolic Analysis
Edition. This
is the "full" commercial version
ARTicles:
Static Hedging & Structuring 101 - Using Maxima®
: "live" notebook and calculator for basic vanilla & exotic options
static replication and structuring, available Jun/06.
Click here for ARTWare Home
Available at the
ARTShop
Tell a Friend

**Pr/rO
is also included as part of the ARTPr/rO
advisory service.