finMath lib documentation
net.finmath.marketdata.model.curves

## Class DiscountCurveRenormalized

• java.lang.Object
• net.finmath.marketdata.model.curves.DiscountCurveRenormalized
• All Implemented Interfaces:
Cloneable, ParameterObjectInterface, CurveInterface, DiscountCurveInterface

public class DiscountCurveRenormalized
extends Object
implements DiscountCurveInterface
A discount curve $$t \mapsto df(t)$$ with property $$df(t_{0}) = 1$$ for a given $$t_{0}$$ derived from a base discount curve by a constant skaling.
Author:
Christian Fries
• ### Constructor Summary

Constructors
Constructor and Description
DiscountCurveRenormalized(String name, LocalDate referenceDate, LocalDate spotDate, String baseCurveName)
• ### Method Summary

All Methods
Modifier and Type Method and Description
DiscountCurveRenormalized clone()
Create a deep copied clone.
CurveBuilderInterface getCloneBuilder()
Returns a curve builder bases on a clone of this curve.
CurveInterface getCloneForParameter(double[] value)
Create a clone with a modified parameter.
double getDiscountFactor(AnalyticModelInterface model, double maturity)
Returns the discount factor for the corresponding maturity.
double getDiscountFactor(double maturity)
Returns the discount factor for the corresponding maturity.
String getName()
Get the name of the curve.
double[] getParameter()
Get the current parameter associated with the state of the objects.
LocalDate getReferenceDate()
Return the reference date of this curve, i.e. the date associated with t=0.
double getValue(AnalyticModelInterface model, double time)
Returns the value for the time using the interpolation method associated with this curve within a given context, i.e., a model.
double getValue(double time)
Returns the value for the time using the interpolation method associated with this curve.
void setParameter(double[] parameter)
Set the current parameter and change the state of the objects.
• ### Methods inherited from class java.lang.Object

equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
• ### Constructor Detail

• #### DiscountCurveRenormalized

public DiscountCurveRenormalized(String name,
LocalDate referenceDate,
LocalDate spotDate,
String baseCurveName)
• ### Method Detail

• #### getName

public String getName()
Description copied from interface: CurveInterface
Get the name of the curve.
Specified by:
getName in interface CurveInterface
Returns:
The name of this curve
• #### getReferenceDate

public LocalDate getReferenceDate()
Description copied from interface: CurveInterface
Return the reference date of this curve, i.e. the date associated with t=0. May be null in case the curve is not associated with a fixed date (e.g. a time homogenous model).
Specified by:
getReferenceDate in interface CurveInterface
Returns:
The date identified as t=0.
• #### getValue

public double getValue(double time)
Description copied from interface: CurveInterface
Returns the value for the time using the interpolation method associated with this curve.
Specified by:
getValue in interface CurveInterface
Parameters:
time - Time for which the value should be returned.
Returns:
The value at the give time.
• #### getValue

public double getValue(AnalyticModelInterface model,
double time)
Description copied from interface: CurveInterface
Returns the value for the time using the interpolation method associated with this curve within a given context, i.e., a model. The model (context) is needed only if the curve relies on another curve. Examples are a forward curve which relies on a discount curve or a discount curve which is defined via a spread over another curve.
Specified by:
getValue in interface CurveInterface
Parameters:
model - An analytic model providing a context.
time - Time for which the value should be returned.
Returns:
The value at the give time.
• #### getCloneBuilder

public CurveBuilderInterface getCloneBuilder()
throws CloneNotSupportedException
Description copied from interface: CurveInterface
Returns a curve builder bases on a clone of this curve. Using that curve builder you may create a new curve from this curve by adding points or changing properties. Note: The clone has the same name than this one.
Specified by:
getCloneBuilder in interface CurveInterface
Returns:
An object implementing the CurveBuilderInterface where the underlying curve is a clone of this curve.
Throws:
CloneNotSupportedException - Thrown, when this curve could not be cloned.
• #### getCloneForParameter

public CurveInterface getCloneForParameter(double[] value)
throws CloneNotSupportedException
Description copied from interface: ParameterObjectInterface
Create a clone with a modified parameter.
Specified by:
getCloneForParameter in interface ParameterObjectInterface
Specified by:
getCloneForParameter in interface CurveInterface
Parameters:
value - The new parameter.
Returns:
A clone with an otherwise modified parameter.
Throws:
CloneNotSupportedException - Thrown, when the curve could not be cloned.
• #### getParameter

public double[] getParameter()
Description copied from interface: ParameterObjectInterface
Get the current parameter associated with the state of the objects.
Specified by:
getParameter in interface ParameterObjectInterface
Returns:
The parameter.
• #### setParameter

public void setParameter(double[] parameter)
Description copied from interface: ParameterObjectInterface
Set the current parameter and change the state of the objects.
Specified by:
setParameter in interface ParameterObjectInterface
Parameters:
parameter - The parameter associated with the new state of the objects.
• #### getDiscountFactor

public double getDiscountFactor(double maturity)
Description copied from interface: DiscountCurveInterface
Returns the discount factor for the corresponding maturity. This getter is not optimized for performance.
Specified by:
getDiscountFactor in interface DiscountCurveInterface
Parameters:
maturity - The maturity for which the discount factor is requested.
Returns:
The discount factor (i.e., price of the zero coupon bond with given maturity and notional 1.
• #### getDiscountFactor

public double getDiscountFactor(AnalyticModelInterface model,
double maturity)
Description copied from interface: DiscountCurveInterface
Returns the discount factor for the corresponding maturity. This getter is not optimized for performance.
Specified by:
getDiscountFactor in interface DiscountCurveInterface
Parameters:
model - An analytic model providing a context. Some curves do not need this (can be null).
maturity - The maturity for which the discount factor is requested.
Returns:
The discount factor (i.e., price of the zero coupon bond with given maturity and notional 1.
• #### clone

public DiscountCurveRenormalized clone()
throws CloneNotSupportedException
Description copied from interface: CurveInterface
Create a deep copied clone.
Specified by:
clone in interface CurveInterface
Overrides:
clone in class Object
Returns:
A clone (deep copied).
Throws:
CloneNotSupportedException - Thrown, when the curve could not be cloned.