Class ShapeYield

java.lang.Object
  extended byShapeFunction
      extended byShapeYield

public class ShapeYield
extends ShapeFunction

ShapeYield -- Yield curve / bond term structure

See Also:
Solution.discretize(ShapeFunction)

Field Summary
 
Fields inherited from class ShapeFunction
amplitude, curvature, position, slope, width
 
Constructor Summary
ShapeYield(double strike, double amp, double deriv, double curv)
          Creates an instance of the class
 
Method Summary
 double getValue(double xa)
          Evaluates the shape for a real argument
 double getValue(Mesh mesh, double xa)
          Evaluates the shape on a discrete mesh point position.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ShapeYield

public ShapeYield(double strike,
                  double amp,
                  double deriv,
                  double curv)
Creates an instance of the class

Parameters:
strike - The strike price
Method Detail

getValue

public double getValue(double xa)
Evaluates the shape for a real argument

Specified by:
getValue in class ShapeFunction
Parameters:
xa - The argument
Returns:
The value of the function for this argument

getValue

public double getValue(Mesh mesh,
                       double xa)
Evaluates the shape on a discrete mesh point position.

Specified by:
getValue in class ShapeFunction
Parameters:
mesh - The mesh coordinates
xa - The argument
Returns:
The value of the function at the specified mesh location