Class EuropeanOption
java.lang.Object
net.finmath.fouriermethod.products.AbstractFourierTransformProduct
net.finmath.fouriermethod.products.EuropeanOption
- All Implemented Interfaces:
Function<org.apache.commons.math3.complex.Complex, org.apache.commons.math3.complex.Complex>, CharacteristicFunction, FourierTransformProduct, Product
- Direct Known Subclasses:
SingleAssetFourierProductFactory.EuropeanOptionFourierMethod
Implements valuation of a European option on a single asset.
Given a model for an asset S, the European option with strike K, maturity T
pays
max((S(T) - K) * CallOrPut , 0) in T
The class implements the characteristic function of the call option payoff, i.e., its Fourier transform.
max((S(T) - K) * CallOrPut , 0) in T
The class implements the characteristic function of the call option payoff, i.e., its Fourier transform.
- Version:
- 1.0
- Author:
- Christian Fries, Alessandro Gnoatto
-
Constructor Summary
ConstructorsConstructorDescriptionEuropeanOption(double maturity, double strike) Construct a product representing an European option on an asset S (where S the asset with index 0 from the model - single asset case).EuropeanOption(double maturity, double strike, double callOrPutSign) Construct a product representing an European option on an asset S (where S the asset with index 0 from the model - single asset case).EuropeanOption(double maturity, double strike, CallOrPut callOrPutSign) Construct a product representing an European option on an asset S (where S the asset with index 0 from the model - single asset case).EuropeanOption(String underlyingName, double maturity, double strike) Construct a product representing an European option on an asset S (where S the asset with indexunderlyingIndexfrom the model - single asset case).EuropeanOption(String underlyingName, double maturity, double strike, double callOrPutSign) Construct a product representing an European option on an asset S (where S the asset with indexunderlyingIndexfrom the model - single asset case).EuropeanOption(String underlyingName, double maturity, double strike, CallOrPut callOrPutSign) Construct a product representing an European option on an asset S (where S the asset with indexunderlyingIndexfrom the model - single asset case). -
Method Summary
Modifier and TypeMethodDescriptionorg.apache.commons.math3.complex.Complexapply(org.apache.commons.math3.complex.Complex argument) doubleReturn the lower bound of the imaginary part of the domain where the characteristic function can be integrated.doubleReturn the upper bound of the imaginary part of the domain where the characteristic function can be integrated.doubleReturn the maturity of the associated payoff.doubledoubleThis method returns the value random variable of the product within the specified model, evaluated at a given evalutationTime.Methods inherited from class AbstractFourierTransformProduct
getValue, getValues
-
Constructor Details
-
EuropeanOption
Construct a product representing an European option on an asset S (where S the asset with indexunderlyingIndexfrom the model - single asset case).- Parameters:
underlyingName- Name of the underlyingmaturity- The maturity T in the option payoff max(sign * (S(T)-K),0).strike- The strike K in the option payoff max(sign * (S(T)-K),0).callOrPutSign- The sign in the payoff.
-
EuropeanOption
public EuropeanOption(String underlyingName, double maturity, double strike, CallOrPut callOrPutSign) Construct a product representing an European option on an asset S (where S the asset with indexunderlyingIndexfrom the model - single asset case).- Parameters:
underlyingName- Name of the underlyingmaturity- The maturity T in the option payoff max(sign * (S(T)-K),0).strike- The strike K in the option payoff max(sign * (S(T)-K),0).callOrPutSign- The sign in the payoff.
-
EuropeanOption
public EuropeanOption(double maturity, double strike, double callOrPutSign) Construct a product representing an European option on an asset S (where S the asset with index 0 from the model - single asset case).- Parameters:
maturity- The maturity T in the option payoff max(S(T)-K,0)strike- The strike K in the option payoff max(S(T)-K,0).callOrPutSign- The sign in the payoff.
-
EuropeanOption
Construct a product representing an European option on an asset S (where S the asset with index 0 from the model - single asset case).- Parameters:
maturity- The maturity T in the option payoff max(S(T)-K,0)strike- The strike K in the option payoff max(S(T)-K,0).callOrPutSign- The sign in the payoff.
-
EuropeanOption
Construct a product representing an European option on an asset S (where S the asset with indexunderlyingIndexfrom the model - single asset case).- Parameters:
underlyingName- Name of the underlyingmaturity- The maturity T in the option payoff max(S(T)-K,0)strike- The strike K in the option payoff max(S(T)-K,0).
-
EuropeanOption
public EuropeanOption(double maturity, double strike) Construct a product representing an European option on an asset S (where S the asset with index 0 from the model - single asset case).- Parameters:
maturity- The maturity T in the option payoff max(S(T)-K,0)strike- The strike K in the option payoff max(S(T)-K,0).
-
-
Method Details
-
apply
public org.apache.commons.math3.complex.Complex apply(org.apache.commons.math3.complex.Complex argument) -
getValue
Description copied from interface:FourierTransformProductThis method returns the value random variable of the product within the specified model, evaluated at a given evalutationTime. Note: For a lattice this is often the value conditional to evalutationTime, for a Monte-Carlo simulation this is the (sum of) value discounted to evaluation time. Cashflows prior evaluationTime are not considered.- Specified by:
getValuein interfaceFourierTransformProduct- Overrides:
getValuein classAbstractFourierTransformProduct- Parameters:
model- The model used to price the product.- Returns:
- The random variable representing the value of the product discounted to evaluation time
- Throws:
CalculationException- Thrown if the valuation fails, specific cause may be available via thecause()method.
-
getUnderlyingName
-
getMaturity
public double getMaturity()Description copied from interface:FourierTransformProductReturn the maturity of the associated payoff.- Specified by:
getMaturityin interfaceFourierTransformProduct- Specified by:
getMaturityin classAbstractFourierTransformProduct- Returns:
- The maturity of the associated payoff.
-
getStrike
public double getStrike() -
getIntegrationDomainImagLowerBound
public double getIntegrationDomainImagLowerBound()Description copied from interface:FourierTransformProductReturn the lower bound of the imaginary part of the domain where the characteristic function can be integrated.- Specified by:
getIntegrationDomainImagLowerBoundin interfaceFourierTransformProduct- Specified by:
getIntegrationDomainImagLowerBoundin classAbstractFourierTransformProduct- Returns:
- the lower bound of the imaginary part of the domain of integration.
-
getIntegrationDomainImagUpperBound
public double getIntegrationDomainImagUpperBound()Description copied from interface:FourierTransformProductReturn the upper bound of the imaginary part of the domain where the characteristic function can be integrated.- Specified by:
getIntegrationDomainImagUpperBoundin interfaceFourierTransformProduct- Specified by:
getIntegrationDomainImagUpperBoundin classAbstractFourierTransformProduct- Returns:
- the upper bound of the imaginary part of the domain of integration.
-