com.ftlabs.fisa.calc
Class BinaryYieldConvergence

java.lang.Object
  extended by com.ftlabs.fisa.calc.AbstractYieldConvergence
      extended by com.ftlabs.fisa.calc.BinaryYieldConvergence
All Implemented Interfaces:
YieldConvergence, java.io.Serializable

public class BinaryYieldConvergence
extends AbstractYieldConvergence

See Also:
Serialized Form

Field Summary
 
Fields inherited from class com.ftlabs.fisa.calc.AbstractYieldConvergence
precision
 
Constructor Summary
BinaryYieldConvergence()
           
BinaryYieldConvergence(double precision)
           
BinaryYieldConvergence(double precision, double adjustmentSteps)
           
 
Method Summary
 double converge(double price, double approximateYield, YieldConvergable convergable)
          Converge upon a yield from the provided price and approximate yield.
 double getAdjustmentSteps()
           
 void setAdjustmentSteps(double adjustmentSteps)
           
 
Methods inherited from class com.ftlabs.fisa.calc.AbstractYieldConvergence
getPrecision, setPrecision
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BinaryYieldConvergence

public BinaryYieldConvergence()

BinaryYieldConvergence

public BinaryYieldConvergence(double precision)

BinaryYieldConvergence

public BinaryYieldConvergence(double precision,
                              double adjustmentSteps)
Method Detail

converge

public double converge(double price,
                       double approximateYield,
                       YieldConvergable convergable)
                throws CalculationException
Description copied from interface: YieldConvergence
Converge upon a yield from the provided price and approximate yield.

Parameters:
price - price.
approximateYield - A starting approximate yield.
convergable - The YieldConvergable implementation used to calculate price.
Returns:
yield.
Throws:
CalculationException

setAdjustmentSteps

public void setAdjustmentSteps(double adjustmentSteps)

getAdjustmentSteps

public double getAdjustmentSteps()