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 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<meta name="robots" content="none">
<title>CPILeg Class Reference</title>
<link rel="stylesheet" href="quantlib.css" type="text/css">
<link rel="stylesheet" href="print.css" type="text/css" media="print">
<link rel="shortcut icon" href="favicon.ico" type="image/x-icon">
<link rel="icon" href="favicon.ico" type="image/x-icon">
</head>
<body>
<div id="container">
<div id="header">
<img class="titleimage"
src="QL-title.jpg" width="185" height="50" border="0"
alt="QuantLib">
<br>
<h3 class="subtitle">A free/open-source library for quantitative finance</h3>
</div>
<div id="menu">
<h3 class="navbartitle">Version 1.2</h3>
<hr>
<h3 class="navbartitle">Getting started</h3>
<ul class="navbarlist">
<li class="navlink"><a href="index.html">Introduction</a></li>
<li class="navlink"><a href="where.html">Where to get QuantLib</a></li>
<li class="navlink"><a href="install.html">Installation</a></li>
<li class="navlink"><a href="config.html">Configuration</a></li>
<li class="navlink"><a href="usage.html">Usage</a></li>
<li class="navlink"><a href="history.html">Version history</a></li>
<li class="navlink"><a href="resources.html">Additional resources</a></li>
<li class="navlink"><a href="group.html">The QuantLib group</a></li>
<li class="navlink"><a href="license.html">Copyright and license</a></li>
</ul>
<hr>
<h3 class="navbartitle">Reference manual</h3>
<ul class="navbarlist">
<li class="navlink"><a href="modules.html">Modules</a></li>
<li class="navlink"><a href="hierarchy.html">Class Hierarchy</a></li>
<li class="navlink"><a href="annotated.html">Compound List</a></li>
<li class="navlink"><a href="files.html">File List</a></li>
<li class="navlink"><a href="functions.html">Compound Members</a></li>
<li class="navlink"><a href="globals.html">File Members</a></li>
<li class="navlink"><a href="todo.html">Todo List</a></li>
<li class="navlink"><a href="bug.html">Known Bugs</a></li>
<li class="navlink"><a href="caveats.html">Caveats</a></li>
<li class="navlink"><a href="test.html">Test Suite</a></li>
<li class="navlink"><a href="examples.html">Examples</a></li>
</ul>
</div>
<div id="content">
<!--Doxygen-generated content-->
<!-- Generated by Doxygen 1.7.6.1 -->
<div id="nav-path" class="navpath">
<ul>
<li class="navelem"><b>QuantLib</b> </li>
<li class="navelem"><a class="el" href="class_quant_lib_1_1_c_p_i_leg.html">CPILeg</a> </li>
</ul>
</div>
</div>
<div class="header">
<div class="summary">
<a href="#pub-methods">Public Member Functions</a> </div>
<div class="headertitle">
<div class="title">CPILeg Class Reference</div> </div>
</div><!--header-->
<div class="contents">
<!-- doxytag: class="QuantLib::CPILeg" -->
<p>Helper class building a sequence of capped/floored CPI coupons.
<a href="class_quant_lib_1_1_c_p_i_leg.html#details">More...</a></p>
<p><code>#include <ql/cashflows/cpicoupon.hpp></code></p>
<p><a href="class_quant_lib_1_1_c_p_i_leg-members.html">List of all members.</a></p>
<table class="memberdecls">
<tr><td colspan="2"><h2><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="afdebf2b09461c674e4840411fb00ee94"></a><!-- doxytag: member="QuantLib::CPILeg::CPILeg" ref="afdebf2b09461c674e4840411fb00ee94" args="(const Schedule &schedule, const boost::shared_ptr< ZeroInflationIndex > &index, const Real baseCPI, const Period &observationLag)" -->
 </td><td class="memItemRight" valign="bottom"><b>CPILeg</b> (const <a class="el" href="class_quant_lib_1_1_schedule.html">Schedule</a> &schedule, const boost::shared_ptr< <a class="el" href="class_quant_lib_1_1_zero_inflation_index.html">ZeroInflationIndex</a> > &index, const <a class="el" href="group__types.html#ga4bdf4bfe76b9ffa6fa64c47d8bfa0c78">Real</a> baseCPI, const <a class="el" href="class_quant_lib_1_1_period.html">Period</a> &observationLag)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a1d033c53369011d9d247b1e212033291"></a><!-- doxytag: member="QuantLib::CPILeg::withNotionals" ref="a1d033c53369011d9d247b1e212033291" args="(Real notional)" -->
<a class="el" href="class_quant_lib_1_1_c_p_i_leg.html">CPILeg</a> & </td><td class="memItemRight" valign="bottom"><b>withNotionals</b> (<a class="el" href="group__types.html#ga4bdf4bfe76b9ffa6fa64c47d8bfa0c78">Real</a> notional)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="aa74d5851332e0be079c7e89111ce614d"></a><!-- doxytag: member="QuantLib::CPILeg::withNotionals" ref="aa74d5851332e0be079c7e89111ce614d" args="(const std::vector< Real > &notionals)" -->
<a class="el" href="class_quant_lib_1_1_c_p_i_leg.html">CPILeg</a> & </td><td class="memItemRight" valign="bottom"><b>withNotionals</b> (const std::vector< <a class="el" href="group__types.html#ga4bdf4bfe76b9ffa6fa64c47d8bfa0c78">Real</a> > &notionals)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="abdaa18d76e2652658f4a158de41264c9"></a><!-- doxytag: member="QuantLib::CPILeg::withFixedRates" ref="abdaa18d76e2652658f4a158de41264c9" args="(Real fixedRate)" -->
<a class="el" href="class_quant_lib_1_1_c_p_i_leg.html">CPILeg</a> & </td><td class="memItemRight" valign="bottom"><b>withFixedRates</b> (<a class="el" href="group__types.html#ga4bdf4bfe76b9ffa6fa64c47d8bfa0c78">Real</a> fixedRate)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a5c439973f2a0a05466177559594e95d6"></a><!-- doxytag: member="QuantLib::CPILeg::withFixedRates" ref="a5c439973f2a0a05466177559594e95d6" args="(const std::vector< Real > &fixedRates)" -->
<a class="el" href="class_quant_lib_1_1_c_p_i_leg.html">CPILeg</a> & </td><td class="memItemRight" valign="bottom"><b>withFixedRates</b> (const std::vector< <a class="el" href="group__types.html#ga4bdf4bfe76b9ffa6fa64c47d8bfa0c78">Real</a> > &fixedRates)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a2361eb41bba3b4f366fe53cd248e85e3"></a><!-- doxytag: member="QuantLib::CPILeg::withPaymentDayCounter" ref="a2361eb41bba3b4f366fe53cd248e85e3" args="(const DayCounter &)" -->
<a class="el" href="class_quant_lib_1_1_c_p_i_leg.html">CPILeg</a> & </td><td class="memItemRight" valign="bottom"><b>withPaymentDayCounter</b> (const <a class="el" href="class_quant_lib_1_1_day_counter.html">DayCounter</a> &)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ac6ea5169a989427e6f60d59332efe9a3"></a><!-- doxytag: member="QuantLib::CPILeg::withPaymentAdjustment" ref="ac6ea5169a989427e6f60d59332efe9a3" args="(BusinessDayConvention)" -->
<a class="el" href="class_quant_lib_1_1_c_p_i_leg.html">CPILeg</a> & </td><td class="memItemRight" valign="bottom"><b>withPaymentAdjustment</b> (<a class="el" href="group__datetime.html#gaff46c5ae9385d20709bedade86edd368">BusinessDayConvention</a>)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a3a895c5e50e0f7594f6825c6a916f1d5"></a><!-- doxytag: member="QuantLib::CPILeg::withFixingDays" ref="a3a895c5e50e0f7594f6825c6a916f1d5" args="(Natural fixingDays)" -->
<a class="el" href="class_quant_lib_1_1_c_p_i_leg.html">CPILeg</a> & </td><td class="memItemRight" valign="bottom"><b>withFixingDays</b> (<a class="el" href="group__types.html#ga7e529c39c477ba1f5a22264d93e8457a">Natural</a> fixingDays)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a649059106307a11cb118f120562456e3"></a><!-- doxytag: member="QuantLib::CPILeg::withFixingDays" ref="a649059106307a11cb118f120562456e3" args="(const std::vector< Natural > &fixingDays)" -->
<a class="el" href="class_quant_lib_1_1_c_p_i_leg.html">CPILeg</a> & </td><td class="memItemRight" valign="bottom"><b>withFixingDays</b> (const std::vector< <a class="el" href="group__types.html#ga7e529c39c477ba1f5a22264d93e8457a">Natural</a> > &fixingDays)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a98934189fb90a8e1884d21066692f7bc"></a><!-- doxytag: member="QuantLib::CPILeg::withObservationInterpolation" ref="a98934189fb90a8e1884d21066692f7bc" args="(CPI::InterpolationType)" -->
<a class="el" href="class_quant_lib_1_1_c_p_i_leg.html">CPILeg</a> & </td><td class="memItemRight" valign="bottom"><b>withObservationInterpolation</b> (CPI::InterpolationType)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="af3c199bdab008e3c87b82d3e32a41dc6"></a><!-- doxytag: member="QuantLib::CPILeg::withSubtractInflationNominal" ref="af3c199bdab008e3c87b82d3e32a41dc6" args="(bool)" -->
<a class="el" href="class_quant_lib_1_1_c_p_i_leg.html">CPILeg</a> & </td><td class="memItemRight" valign="bottom"><b>withSubtractInflationNominal</b> (bool)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a61624a303130014d7a136be6ea68ac17"></a><!-- doxytag: member="QuantLib::CPILeg::withSpreads" ref="a61624a303130014d7a136be6ea68ac17" args="(Spread spread)" -->
<a class="el" href="class_quant_lib_1_1_c_p_i_leg.html">CPILeg</a> & </td><td class="memItemRight" valign="bottom"><b>withSpreads</b> (<a class="el" href="group__types.html#gae7427f4743503002b0c6eeeefae91a3d">Spread</a> spread)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a31971e5cd50f5a6dc4cf113208638f34"></a><!-- doxytag: member="QuantLib::CPILeg::withSpreads" ref="a31971e5cd50f5a6dc4cf113208638f34" args="(const std::vector< Spread > &spreads)" -->
<a class="el" href="class_quant_lib_1_1_c_p_i_leg.html">CPILeg</a> & </td><td class="memItemRight" valign="bottom"><b>withSpreads</b> (const std::vector< <a class="el" href="group__types.html#gae7427f4743503002b0c6eeeefae91a3d">Spread</a> > &spreads)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a8e2373571d0558faa245654d4eaf81b6"></a><!-- doxytag: member="QuantLib::CPILeg::withCaps" ref="a8e2373571d0558faa245654d4eaf81b6" args="(Rate cap)" -->
<a class="el" href="class_quant_lib_1_1_c_p_i_leg.html">CPILeg</a> & </td><td class="memItemRight" valign="bottom"><b>withCaps</b> (<a class="el" href="group__types.html#gaede435af51236692b1107d7639581d39">Rate</a> cap)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a7594649104bc149550810cfd9bc78de1"></a><!-- doxytag: member="QuantLib::CPILeg::withCaps" ref="a7594649104bc149550810cfd9bc78de1" args="(const std::vector< Rate > &caps)" -->
<a class="el" href="class_quant_lib_1_1_c_p_i_leg.html">CPILeg</a> & </td><td class="memItemRight" valign="bottom"><b>withCaps</b> (const std::vector< <a class="el" href="group__types.html#gaede435af51236692b1107d7639581d39">Rate</a> > &caps)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a03c4d807a6168dd16f7428e8c31771c9"></a><!-- doxytag: member="QuantLib::CPILeg::withFloors" ref="a03c4d807a6168dd16f7428e8c31771c9" args="(Rate floor)" -->
<a class="el" href="class_quant_lib_1_1_c_p_i_leg.html">CPILeg</a> & </td><td class="memItemRight" valign="bottom"><b>withFloors</b> (<a class="el" href="group__types.html#gaede435af51236692b1107d7639581d39">Rate</a> floor)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a629e599fb0415e479a3c22e77e0855b7"></a><!-- doxytag: member="QuantLib::CPILeg::withFloors" ref="a629e599fb0415e479a3c22e77e0855b7" args="(const std::vector< Rate > &floors)" -->
<a class="el" href="class_quant_lib_1_1_c_p_i_leg.html">CPILeg</a> & </td><td class="memItemRight" valign="bottom"><b>withFloors</b> (const std::vector< <a class="el" href="group__types.html#gaede435af51236692b1107d7639581d39">Rate</a> > &floors)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ab90967eddf8d006442846cf44ea38756"></a><!-- doxytag: member="QuantLib::CPILeg::operator Leg" ref="ab90967eddf8d006442846cf44ea38756" args="() const " -->
 </td><td class="memItemRight" valign="bottom"><b>operator Leg</b> () const </td></tr>
</table>
<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
<div class="textblock"><p>Helper class building a sequence of capped/floored CPI coupons. </p>
<p>Also allowing for the inflated notional at the end... especially if there is only one date in the schedule. If a fixedRate is zero you get a <a class="el" href="class_quant_lib_1_1_fixed_rate_coupon.html" title="Coupon paying a fixed interest rate">FixedRateCoupon</a>, otherwise you get a ZeroInflationCoupon.</p>
<p>payoff is: spread + fixedRate x index </p>
</div></div><!-- contents -->
</div>
<div class="footer">
<div class="endmatter">
Documentation generated by
<a href="http://www.doxygen.org">Doxygen</a> 1.7.6.1
</div>
</div>
</div>
</body>
</html>
|