Class EuropeanOption

java.lang.Object
net.finmath.finitedifference.products.EuropeanOption
All Implemented Interfaces:
FiniteDifference1DBoundary, FiniteDifference1DProduct, Product

public class EuropeanOption extends Object implements FiniteDifference1DProduct, FiniteDifference1DBoundary
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.
Version:
1.0
Author:
Christian Fries, Ralph Rudd, Alessandro Gnoatto
  • Constructor Summary

    Constructors
    Constructor
    Description
    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).
    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 index underlyingIndex from 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 index underlyingIndex from 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 index underlyingIndex from the model - single asset case).
  • Method Summary

    Modifier and Type
    Method
    Description
     
    double
     
    double
     
     
    double[][]
    getValue​(double evaluationTime, FiniteDifference1DModel model)
    Return the value of the product under the given model.
    double
    getValueAtLowerBoundary​(FiniteDifference1DModel model, double currentTime, double stockPrice)
    Return the value of the value process at the lower boundary for a given time and asset value.
    double
    getValueAtUpperBoundary​(FiniteDifference1DModel model, double currentTime, double stockPrice)
    Return the value of the value process at the upper boundary for a given time and asset value.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface net.finmath.finitedifference.products.FiniteDifference1DProduct

    getValue

    Methods inherited from interface net.finmath.modelling.Product

    getValues
  • Constructor Details

    • EuropeanOption

      public 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 index underlyingIndex from the model - single asset case).
      Parameters:
      underlyingName - Name of the underlying
      maturity - 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 index underlyingIndex from the model - single asset case).
      Parameters:
      underlyingName - Name of the underlying
      maturity - 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

      public 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).
      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

      public EuropeanOption(String underlyingName, double maturity, double strike)
      Construct a product representing an European option on an asset S (where S the asset with index underlyingIndex from the model - single asset case).
      Parameters:
      underlyingName - Name of the underlying
      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).
    • 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

    • getValue

      public double[][] getValue(double evaluationTime, FiniteDifference1DModel model)
      Description copied from interface: FiniteDifference1DProduct
      Return the value of the product under the given model.
      Specified by:
      getValue in interface FiniteDifference1DProduct
      Parameters:
      evaluationTime - The time at which the value (valuation) is requested.
      model - The model under which the valuation should be performed.
      Returns:
      The random variable representing the valuation result.
    • getValueAtLowerBoundary

      public double getValueAtLowerBoundary(FiniteDifference1DModel model, double currentTime, double stockPrice)
      Description copied from interface: FiniteDifference1DBoundary
      Return the value of the value process at the lower boundary for a given time and asset value.
      Specified by:
      getValueAtLowerBoundary in interface FiniteDifference1DBoundary
      Parameters:
      model - The model which uses the boundary condition (provides model parameters)
      currentTime - The time at which the boundary is observed.
      stockPrice - The value of the asset specifying the location of the boundary.
      Returns:
      the value process at the lower boundary
    • getValueAtUpperBoundary

      public double getValueAtUpperBoundary(FiniteDifference1DModel model, double currentTime, double stockPrice)
      Description copied from interface: FiniteDifference1DBoundary
      Return the value of the value process at the upper boundary for a given time and asset value.
      Specified by:
      getValueAtUpperBoundary in interface FiniteDifference1DBoundary
      Parameters:
      model - TODO
      currentTime - The time at which the boundary is observed.
      stockPrice - The value of the asset specifying the location of the boundary.
      Returns:
      the value process at the upper boundary
    • getUnderlyingName

      public String getUnderlyingName()
    • getMaturity

      public double getMaturity()
    • getStrike

      public double getStrike()
    • getCallOrPutSign

      public CallOrPut getCallOrPutSign()