Class ForwardCurve

java.lang.Object
com.quantfinlib.pricing.ForwardCurve

public final class ForwardCurve extends Object
Implied FX forward curve construction from market outright forwards, with interpolation, implied rate differentials, and covered-interest-parity arbitrage checks against deposit rates.
  • Constructor Summary

    Constructors
    Constructor
    Description
    ForwardCurve(double spot)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    addPoint(double tenorYears, double outrightForward)
     
    double
    forward(double tenorYears)
    Interpolated outright forward at the tenor (linear in forward points between pillars; flat-slope extrapolation beyond the last pillar).
    double
    forwardPoints(double tenorYears)
    Forward points at the tenor (outright minus spot).
    double
    impliedRateDifferential(double tenorYears)
    Implied continuously-compounded rate differential (domestic minus foreign) from covered interest parity: F = S * e^((rd-rf)*t).
    double
    mispricingBps(double tenorYears, double domesticRate, double foreignRate)
    Covered-interest-parity arbitrage check: market forward versus the deposit-implied forward, in basis points (positive = market forward rich).
    double
     
    static double
    theoreticalForward(double spot, double domesticRate, double foreignRate, double tenorYears)
    CIP-theoretical forward from SIMPLE deposit rates (see the convention note on impliedRateDifferential(double)).

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • ForwardCurve

      public ForwardCurve(double spot)
  • Method Details

    • addPoint

      public ForwardCurve addPoint(double tenorYears, double outrightForward)
    • spot

      public double spot()
    • forward

      public double forward(double tenorYears)
      Interpolated outright forward at the tenor (linear in forward points between pillars; flat-slope extrapolation beyond the last pillar).
    • forwardPoints

      public double forwardPoints(double tenorYears)
      Forward points at the tenor (outright minus spot).
    • impliedRateDifferential

      public double impliedRateDifferential(double tenorYears)
      Implied continuously-compounded rate differential (domestic minus foreign) from covered interest parity: F = S * e^((rd-rf)*t).

      Convention note — this method is CONTINUOUS while theoreticalForward(double, double, double, double) uses SIMPLE deposit rates, because each matches how its own input is quoted (a differential is usually consumed in cc form; deposits are quoted simple). Feeding this output back through theoreticalForward therefore shows a spurious ~12bp "basis" at 1y/5% that is pure compounding convention, not arbitrage — convert first.

    • theoreticalForward

      public static double theoreticalForward(double spot, double domesticRate, double foreignRate, double tenorYears)
      CIP-theoretical forward from SIMPLE deposit rates (see the convention note on impliedRateDifferential(double)).
    • mispricingBps

      public double mispricingBps(double tenorYears, double domesticRate, double foreignRate)
      Covered-interest-parity arbitrage check: market forward versus the deposit-implied forward, in basis points (positive = market forward rich).