net.finmath.marketdata.model.volatilities
Class AbstractVolatilitySurface
- java.lang.Object
-
- net.finmath.marketdata.model.volatilities.AbstractVolatilitySurface
-
- All Implemented Interfaces:
- java.lang.Cloneable, VolatilitySurfaceInterface
- Direct Known Subclasses:
- AbstractVolatilitySurfaceParametric, CapletVolatilities, CapletVolatilitiesParametricFourParameterPicewiseConstant
public abstract class AbstractVolatilitySurface extends java.lang.Object implements VolatilitySurfaceInterface, java.lang.Cloneable
Abstract base class for a volatility surface. It stores the name of the surface and provides some convenient way of getting values.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface net.finmath.marketdata.model.volatilities.VolatilitySurfaceInterface
VolatilitySurfaceInterface.QuotingConvention
-
-
Constructor Summary
Constructors Constructor and Description AbstractVolatilitySurface(java.lang.String name, java.util.Calendar referenceDate)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description java.lang.Objectclone()doubleconvertFromTo(AnalyticModelInterface model, double optionMaturity, double optionStrike, double value, VolatilitySurfaceInterface.QuotingConvention fromQuotingConvention, VolatilitySurfaceInterface.QuotingConvention toQuotingConvention)Convert the value of a caplet from on quoting convention to another quoting convention.doubleconvertFromTo(double optionMaturity, double optionStrike, double value, VolatilitySurfaceInterface.QuotingConvention fromQuotingConvention, VolatilitySurfaceInterface.QuotingConvention toQuotingConvention)Convert the value of a caplet from one quoting convention to another quoting convention.java.lang.StringgetName()Returns the name of the volatility surface.VolatilitySurfaceInterface.QuotingConventiongetQuotingConvention()Return the default quoting convention of this surface.java.util.CalendargetReferenceDate()Return the reference date of this surface, i.e.java.lang.StringtoString()-
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface net.finmath.marketdata.model.volatilities.VolatilitySurfaceInterface
getValue, getValue
-
-
-
-
Constructor Detail
-
AbstractVolatilitySurface
public AbstractVolatilitySurface(java.lang.String name, java.util.Calendar referenceDate)
-
-
Method Detail
-
getName
public java.lang.String getName()
Description copied from interface:VolatilitySurfaceInterfaceReturns the name of the volatility surface.- Specified by:
getNamein interfaceVolatilitySurfaceInterface- Returns:
- The name of the volatility surface.
-
getReferenceDate
public java.util.Calendar getReferenceDate()
Description copied from interface:VolatilitySurfaceInterfaceReturn the reference date of this surface, i.e. the date associated with t=0.- Specified by:
getReferenceDatein interfaceVolatilitySurfaceInterface- Returns:
- The date identified as t=0.
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
clone
public java.lang.Object clone() throws java.lang.CloneNotSupportedException- Overrides:
clonein classjava.lang.Object- Throws:
java.lang.CloneNotSupportedException
-
getQuotingConvention
public VolatilitySurfaceInterface.QuotingConvention getQuotingConvention()
Description copied from interface:VolatilitySurfaceInterfaceReturn the default quoting convention of this surface.- Specified by:
getQuotingConventionin interfaceVolatilitySurfaceInterface- Returns:
- the quotingConvention
-
convertFromTo
public double convertFromTo(AnalyticModelInterface model, double optionMaturity, double optionStrike, double value, VolatilitySurfaceInterface.QuotingConvention fromQuotingConvention, VolatilitySurfaceInterface.QuotingConvention toQuotingConvention)
Convert the value of a caplet from on quoting convention to another quoting convention.- Parameters:
model- An analytic model providing the context when fetching required market date.optionMaturity- Option maturity of the caplet.optionStrike- Option strike of the cpalet.value- Value of the caplet given in the form offromQuotingConvention.fromQuotingConvention- The quoting convention of the given value.toQuotingConvention- The quoting convention requested.- Returns:
- Value of the caplet given in the form of
toQuotingConvention.
-
convertFromTo
public double convertFromTo(double optionMaturity, double optionStrike, double value, VolatilitySurfaceInterface.QuotingConvention fromQuotingConvention, VolatilitySurfaceInterface.QuotingConvention toQuotingConvention)Convert the value of a caplet from one quoting convention to another quoting convention.- Parameters:
optionMaturity- Option maturity of the caplet.optionStrike- Option strike of the caplet.value- Value of the caplet given in the form offromQuotingConvention.fromQuotingConvention- The quoting convention of the given value.toQuotingConvention- The quoting convention requested.- Returns:
- Value of the caplet given in the form of
toQuotingConvention.
-
-
DataMelt 3.0 © DataMelt by jWork.ORG