Class EuropeanOption

java.lang.Object
net.finmath.finitedifference.assetderivativevaluation.products.EuropeanOption
All Implemented Interfaces:
FiniteDifferenceEquityProduct, FiniteDifferenceProduct<FiniteDifferenceEquityModel>, Product

public class EuropeanOption extends Object implements FiniteDifferenceEquityProduct
Finite difference valuation of a European option on a single asset.

Given an underlying price S with strike K and maturity T, the payoff is

max(sign * (S(T) - K), 0),

where sign corresponds to CallOrPut.CALL or CallOrPut.PUT.

Version:
1.0
Author:
Christian Fries, Ralph Rudd, Alessandro Gnoatto
  • Constructor Details

    • EuropeanOption

      public EuropeanOption(String underlyingName, double maturity, double strike, double callOrPutSign)
      Creates a European option for a named underlying.
      Parameters:
      underlyingName - Name of the underlying.
      maturity - Maturity T.
      strike - Strike K.
      callOrPutSign - Payoff sign, where 1.0 corresponds to a call and -1.0 corresponds to a put.
    • EuropeanOption

      public EuropeanOption(String underlyingName, double maturity, double strike, CallOrPut callOrPutSign)
      Creates a European option for a named underlying.
      Parameters:
      underlyingName - Name of the underlying.
      maturity - Maturity T.
      strike - Strike K.
      callOrPutSign - Option type.
    • EuropeanOption

      public EuropeanOption(double maturity, double strike, double callOrPutSign)
      Creates a European option (single-asset case, unnamed underlying).
      Parameters:
      maturity - Maturity T.
      strike - Strike K.
      callOrPutSign - Payoff sign, where 1.0 corresponds to a call and -1.0 corresponds to a put.
    • EuropeanOption

      public EuropeanOption(double maturity, double strike, CallOrPut callOrPutSign)
      Creates a European option (single-asset case, unnamed underlying).
      Parameters:
      maturity - Maturity T.
      strike - Strike K.
      callOrPutSign - Option type.
    • EuropeanOption

      public EuropeanOption(String underlyingName, double maturity, double strike)
      Creates a European call option for a named underlying.
      Parameters:
      underlyingName - Name of the underlying.
      maturity - Maturity T.
      strike - Strike K.
    • EuropeanOption

      public EuropeanOption(double maturity, double strike)
      Creates a European call option (single-asset case, unnamed underlying).
      Parameters:
      maturity - Maturity T.
      strike - Strike K.
  • Method Details

    • getValue

      public double[] getValue(double evaluationTime, FiniteDifferenceEquityModel model)
      Description copied from interface: FiniteDifferenceProduct
      Returns the value.
      Specified by:
      getValue in interface FiniteDifferenceProduct<FiniteDifferenceEquityModel>
      Parameters:
      evaluationTime - The value.
      model - The value.
      Returns:
      The value.
    • getValues

      public double[][] getValues(FiniteDifferenceEquityModel model)
      Description copied from interface: FiniteDifferenceProduct
      Returns the value.
      Specified by:
      getValues in interface FiniteDifferenceProduct<FiniteDifferenceEquityModel>
      Parameters:
      model - The value.
      Returns:
      The value.
    • getUnderlyingName

      public String getUnderlyingName()
      Returns the name of the underlying.
      Returns:
      The underlying name, or null if unspecified.
    • getMaturity

      public double getMaturity()
      Returns the option maturity.
      Returns:
      The maturity.
    • getStrike

      public double getStrike()
      Returns the option strike.
      Returns:
      The strike.
    • getCallOrPut

      public CallOrPut getCallOrPut()
      Returns whether the option is a call or put.
      Returns:
      The option type.
    • getExercise

      public Exercise getExercise()
      Returns the exercise specification.
      Returns:
      The exercise specification.