Class AmericanExercise
java.lang.Object
net.finmath.modelling.AbstractExercise
net.finmath.modelling.AmericanExercise
- All Implemented Interfaces:
Exercise
American exercise: continuous exercise on an interval.
The standard case is exercise from time 0 to maturity, but a later exercise start time can also be specified.
- Author:
- Alessandro Gnoatto
-
Field Summary
Fields inherited from class AbstractExercise
TIME_TOLERANCE -
Constructor Summary
ConstructorsConstructorDescriptionAmericanExercise(double maturity) Creates a standard American exercise from time 0 to maturity.AmericanExercise(double exerciseStartTime, double maturity) Creates an American exercise on the interval [exerciseStartTime, maturity].AmericanExercise(LocalDate referenceDate, LocalDate maturityDate) Creates a standard American exercise from dates.AmericanExercise(LocalDate referenceDate, LocalDate exerciseStartDate, LocalDate maturityDate) Creates an American exercise window from dates. -
Method Summary
Modifier and TypeMethodDescriptiondoubleReturns the first time at which exercise is allowed.booleanReturns true if this is American exercise.booleanReturns true if this is Bermudan exercise.booleanReturns whether exercise is allowed continuously in time.booleanReturns true if this is European exercise.booleanisExerciseAllowed(double time) Returns whether exercise is allowed at the given running time.Methods inherited from class AbstractExercise
getExerciseTimes, getMaturity, isScheduledExerciseTime
-
Constructor Details
-
AmericanExercise
public AmericanExercise(double maturity) Creates a standard American exercise from time 0 to maturity.- Parameters:
maturity- The maturity.
-
AmericanExercise
public AmericanExercise(double exerciseStartTime, double maturity) Creates an American exercise on the interval [exerciseStartTime, maturity].- Parameters:
exerciseStartTime- The first time at which exercise is allowed.maturity- The maturity.
-
AmericanExercise
-
AmericanExercise
-
-
Method Details
-
getExerciseStartTime
public double getExerciseStartTime()Returns the first time at which exercise is allowed.- Returns:
- The exercise start time.
-
isContinuousExercise
public boolean isContinuousExercise()Description copied from interface:ExerciseReturns whether exercise is allowed continuously in time.- Returns:
- True if the exercise right is continuous in time.
-
isExerciseAllowed
public boolean isExerciseAllowed(double time) Description copied from interface:ExerciseReturns whether exercise is allowed at the given running time.This method is interpreted in contractual terms, not in numerical-grid terms. For Bermudan exercise it checks whether the given time matches one of the scheduled exercise times (up to a small tolerance). For American exercise it checks whether the time lies inside the exercise interval.
- Parameters:
time- The running time.- Returns:
- True if exercise is allowed.
-
isEuropean
public boolean isEuropean()Description copied from interface:ExerciseReturns true if this is European exercise.- Returns:
- True if European.
-
isAmerican
public boolean isAmerican()Description copied from interface:ExerciseReturns true if this is American exercise.- Returns:
- True if American.
-
isBermudan
public boolean isBermudan()Description copied from interface:ExerciseReturns true if this is Bermudan exercise.- Returns:
- True if Bermudan.
-