Record Class RateFuture
- Record Components:
meanReversion- Hull-Whitea, per year,>= 0sigma- Hull-White short-rate volatility (absolute, per sqrt year),>= 0
- All Implemented Interfaces:
CurveInstrument
[start, end], quoted by its futures rate
rate = (100 - price)/100.
Futures are margined daily, so the futures rate exceeds the forward
rate by a convexity adjustment. Under the Hull-White one-factor model
dr = (theta(t) - a r) dt + sigma dW the adjustment between the
continuously compounded futures and forward rates over
[t1, t2] is (Hull, Options, Futures and Other Derivatives,
10th ed. 2018, Technical Note 1; Kirikos and Novak 1997, "Convexity
conundrums", Risk 10(3)):
futures_cc - forward_cc = B(t1,t2)/(t2-t1) * [ B(t1,t2)(1 - e^{-2 a t1}) + 2 a B(0,t1)^2 ] * sigma^2 / (4a)
B(s,u) = (1 - e^{-a(u-s)}) / a
with the Ho-Lee limit sigma^2 t1 t2 / 2 as a -> 0
(Hull 2018, section 6.3), used when meanReversion == 0. Following Hull, the
adjustment is applied to continuously compounded rates over the curve's
time axis: the implied futures rate is
(exp((f_cc + CA)(t2 - t1)) - 1)/tau, f_cc the projection
curve's average forward over [t1, t2] and tau from the day
count. Set sigma = 0 for no adjustment.
-
Constructor Summary
ConstructorsConstructorDescriptionRateFuture(LocalDate start, LocalDate end, double rate, DayCount dayCount, double meanReversion, double sigma) Creates an instance of aRateFuturerecord class. -
Method Summary
Modifier and TypeMethodDescriptiondoubleconvexityAdjustment(DiscountCurve curve) This future's adjustment on the curve's time axis.dayCount()Returns the value of thedayCountrecord component.end()Returns the value of theendrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.static doublehullWhiteConvexity(double t1, double t2, double meanReversion, double sigma) Hull-White convexity adjustment (continuously compounded futures minus forward rate) for an index period fromt1tot2years.doubleimpliedQuote(DiscountCurve discount, DiscountCurve projection) The quote implied by the curves, in the units ofCurveInstrument.quote().doubleReturns the value of themeanReversionrecord component.static RateFutureofPrice(LocalDate start, LocalDate end, double price, DayCount dayCount, double meanReversion, double sigma) From an exchange price,rate = (100 - price)/100.The last date the instrument depends on; the bootstrap places a pillar there.doublequote()The market quote as a decimal rate (0.03 = 3%).doublerate()Returns the value of theraterecord component.doublesigma()Returns the value of thesigmarecord component.start()Returns the value of thestartrecord component.final StringtoString()Returns a string representation of this record class.withQuote(double quote) The same instrument with a different quote (used for bump-and-rebuild risk).
-
Constructor Details
-
RateFuture
public RateFuture(LocalDate start, LocalDate end, double rate, DayCount dayCount, double meanReversion, double sigma) Creates an instance of aRateFuturerecord class.- Parameters:
start- the value for thestartrecord componentend- the value for theendrecord componentrate- the value for theraterecord componentdayCount- the value for thedayCountrecord componentmeanReversion- the value for themeanReversionrecord componentsigma- the value for thesigmarecord component
-
-
Method Details
-
ofPrice
public static RateFuture ofPrice(LocalDate start, LocalDate end, double price, DayCount dayCount, double meanReversion, double sigma) From an exchange price,rate = (100 - price)/100. -
hullWhiteConvexity
public static double hullWhiteConvexity(double t1, double t2, double meanReversion, double sigma) Hull-White convexity adjustment (continuously compounded futures minus forward rate) for an index period fromt1tot2years. -
convexityAdjustment
This future's adjustment on the curve's time axis. -
pillarDate
Description copied from interface:CurveInstrumentThe last date the instrument depends on; the bootstrap places a pillar there.- Specified by:
pillarDatein interfaceCurveInstrument
-
quote
public double quote()Description copied from interface:CurveInstrumentThe market quote as a decimal rate (0.03 = 3%).- Specified by:
quotein interfaceCurveInstrument
-
withQuote
Description copied from interface:CurveInstrumentThe same instrument with a different quote (used for bump-and-rebuild risk).- Specified by:
withQuotein interfaceCurveInstrument
-
impliedQuote
Description copied from interface:CurveInstrumentThe quote implied by the curves, in the units ofCurveInstrument.quote().- Specified by:
impliedQuotein interfaceCurveInstrument
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
start
Returns the value of thestartrecord component.- Returns:
- the value of the
startrecord component
-
end
Returns the value of theendrecord component.- Returns:
- the value of the
endrecord component
-
rate
public double rate()Returns the value of theraterecord component.- Returns:
- the value of the
raterecord component
-
dayCount
Returns the value of thedayCountrecord component.- Returns:
- the value of the
dayCountrecord component
-
meanReversion
public double meanReversion()Returns the value of themeanReversionrecord component.- Returns:
- the value of the
meanReversionrecord component
-
sigma
-