1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125
|
/*
Copyright (C) 2000-2003 StatPro Italia srl
This file is part of QuantLib, a free-software/open-source library
for financial quantitative analysts and developers - http://quantlib.org/
QuantLib is free software: you can redistribute it and/or modify it
under the terms of the QuantLib license. You should have received a
copy of the license along with this program; if not, please email
<quantlib-dev@lists.sf.net>. The license is also available online at
<https://www.quantlib.org/license.shtml>.
This program is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the license for more details.
*/
/*!
\example BasketLosses.cpp
This example shows how to model losses across correlated assets.
\example BermudanSwaption.cpp
This example prices a bermudan swaption using different models
calibrated to market swaptions. The calibration examples include
Hull and White's using both an analytic formula as well as
numerically, and Black and Karasinski's model. Using these three
calibrations, Bermudan swaptions are priced for at-the-money,
out-of-the-money and in-the-money volatilities.
\example Bonds.cpp
This example shows how to set up a term structure and then price
some simple bonds. The last part is dedicated to peripherical
computations such as yield-to-price or price-to-yield.
\example CallableBonds.cpp
This example prices a number of callable bonds and compares the
results to known good data.
\example CDS.cpp
This example bootstraps a default-probability curve over a number
of CDS and reprices them.
\example ConvertibleBonds.cpp
For a given set of option parameters, this example computes the
value of a convertible bond with an embedded put option for two
different equity options types (with european and american
exercise features) using the Tsiveriotis-Fernandes method with
different implied tree algorithms. The tree types are
Jarrow-Rudd, Cox-Ross-Rubinstein, Additive equiprobabilities,
Trigeorgis, Tian and Leisen-Reimer.
\example CVAIRS.cpp
This example shows how to calculate credit value adjustment for an
interest rate swap.
\example DiscreteHedging.cpp
This example computes profit and loss of a discrete interval
hedging strategy and compares with the outcome with the results of
Derman and Kamal's Goldman Sachs Equity Derivatives Research Note
"When You Cannot Hedge Continuously: The Corrections to
Black-Scholes". It shows the use of the Monte Carlo framework.
\example EquityOption.cpp
For a given set of option parameters, this example computes the
value of three different equity options types (with european,
bermudan and american exercise features) using different valuation
algorithms. The calculation methods are Black-Scholes (for
european options only), Barone-Adesi/Whaley (american-only),
Bjerksund/Stensland (american), Integral (european), finite
differences, binomial trees, crude Monte Carlo (european-only) and
Sobol-sequence Monte Carlo (european-only).
\example FittedBondCurve.cpp
For a given set of coupons and terms to maturity, this example
computes the value of a bond by fitting the yields to a curve
using different methods. The fitting methods are exponential
splines, simple polynomials, Nelson-Siegel, and cubic B-splines.
It then shifts the evaluation date into the future to compute
implied forward par rates. It also computes yields after small
price shifts.
\example FRA.cpp
This example values a forward-rate agreement (FRA) at different
forward dates under two yield curve assumptions. It thereby
illustrates how set up a term structure, and to use it to price a
simple forward-rate agreement.
\example Gaussian1dModels.cpp
This example shows the use of Gaussian short rate model for
interest rate derivatives.
\example GlobalOptimizer.cpp
This example shows the use of several different optimizers:
firefly algorithm, hybrid simulated annealing, particle swarm
optimization, simulated annealing, and differential evolution.
\example LatentModel.cpp
This example shows the calculation of correlated defaults.
\example MarketModels.cpp
This example shows the use of interest-rate market models.
\example MulticurveBootstrapping.cpp
This example prices an interest rate swap over a term structure
and calculates its fair fixed rate and floating spread.
\example MultidimIntegral.cpp
This example shows multi-dimensional numerical integration.
\example Replication.cpp
This example uses the CompositeInstrument class to statically
replicate a down-and-out barrier options.
\example Repo.cpp
This example values a fixed-coupon bond repurchase (repo). The
repurchase agreement example is set up to use the repo rate to do
all discounting (including the underlying bond income). Forward
delivery price is also obtained using this repo rate. All this is
done by supplying the FixedCouponBondForward constructor with a
flat repo YieldTermStructure.
*/
|