Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members

`#include <LiborFactorLoading.h>`

## Detailed Description

FactorLoading for the log-Libors of a Libor Market Model. Volatilities based on a volatility surface provided by the class VolSurface. The factor loading contains the vector k of volatility scaling factors (book, 6.11.1, k=c). Log-Libor correlations provided by the class Correlations.

With continuous times, set and and let be the matrix Here angular brackets denote the covariation process as usual and is the covariation matrix of the on the interval . This matrix and its upper triangular root are used in the simulation of the time step s->t for the process Y and related processes.

More precisely to simulate the time step (here t is discrete time) we need the matrix , for the drift step as well as its upper triangular root R satisfying for the volatility step.

If a low factor model with r factors is desired we need an approximation , where R(t) has rank at most r and more precisely dimension . The best approximation is obtained by diagonalizing the matrix as where H is a unitary matrix and the eigenvalues of H. One then sets where the are the columns of H.

Author:
Michael J. Meyer

## Public Member Functions

int getDimension () const
const RealArray1DgetDeltas () const
const RealArray1DgetTenorStructure () const
Real getT (int i) const
const RealArray1DgetInitialLibors () const
const RealArray1DgetInitialXLibors () const
RealArray1DgetScalingFactors ()
const UTRRealMatrixgetRho () const
VolSurfacegetVolSurface ()
CorrelationsgetCorrelations ()
LiborFactorLoading (const RealArray1D &L0, const RealArray1D &deltas, const RealArray1D &_k, VolSurface *vols, Correlations *corrs)
void setParameters (const RealArray1D &u)
Real sigma (int i, Real t) const
Real integral_sgi_sgj_rhoij (int i, int j, Real s, Real t) const
Real annualVol (int i) const
const UTRRealMatrixlogLiborCovariationMatrix (int p, int q, Real s, Real t) const
const UTRRealMatrixlogLiborCovariationMatrix (int t) const
const UTRRealMatrixlogLiborCovariationMatrixRoot (int t) const
const RealMatrixreducedRankLogLiborCovariationMatrixRoot (int t, int r) const
void factorAnalysis (int p, int q, Real s, Real t, int r) const
void factorAnalysis (int t, int r) const
void selfTest () const
void factorizationTest (int r) const
std::ostream & printSelf (std::ostream &os) const

## Protected Attributes

int n
RealArray1D delta
RealArray1D T
RealArray1D l
RealArray1D x
RealArray1D k
VolSurfacevol
Correlationscorr
Correlationsrho

## Constructor & Destructor Documentation

Parameters:
 L0 initial libors . deltas array of accrual interval lengths . _k scaling factors for Libor vols. vols volatility surface. corrs correlations.

 LiborFactorLoading::~LiborFactorLoading ( ) ` [inline]`

## Member Function Documentation

 const LiborFactorLoadingType* LiborFactorLoading::getType ( ) const` [inline]`
 Type object, contains integer and string IDs of the VolSurface and Correlations. Definition at line 156 of file LiborFactorLoading.h.

 int LiborFactorLoading::getDimension ( ) const` [inline]`
 Number `n` of forward Libors including . Definition at line 160 of file LiborFactorLoading.h.

 const RealArray1D& LiborFactorLoading::getDeltas ( ) const` [inline]`
 Array of accrual intervals . Definition at line 164 of file LiborFactorLoading.h.

 const RealArray1D& LiborFactorLoading::getTenorStructure ( ) const` [inline]`
 Array of continuous Libor reset times . Definition at line 168 of file LiborFactorLoading.h.

 Real LiborFactorLoading::getT ( int i ) const` [inline]`
 Libor reset date . Definition at line 171 of file LiborFactorLoading.h. References Real.

 const RealArray1D& LiborFactorLoading::getInitialLibors ( ) const` [inline]`
 The array of initial Libors . Definition at line 175 of file LiborFactorLoading.h.

 const RealArray1D& LiborFactorLoading::getInitialXLibors ( ) const` [inline]`
 The array of initial XLibors . Definition at line 179 of file LiborFactorLoading.h.

 RealArray1D& LiborFactorLoading::getScalingFactors ( ) ` [inline]`
 The scaling factor . See book, 6.11.1. Definition at line 183 of file LiborFactorLoading.h.

 The instantaneous log-Libor correlations.

 VolSurface* LiborFactorLoading::getVolSurface ( ) ` [inline]`

 Correlations* LiborFactorLoading::getCorrelations ( ) ` [inline]`

 Set the parameters of the factorloading from the vector X. The first 4 coordinates populate the VolSurface the rest goes to the Correlations. Index base of u must be zero.

Volatility of forward Libor . See book, 6.4.

Parameters:
 i Libor index. t continuous time.

 Real LiborFactorLoading::integral_sgi_sgj_rhoij ( int i, int j, Real s, Real t ) const

The integral neeeded for the distribution of time step increments s->t. See book, 6.5.1.

Parameters:
 i,j forward Libor indices. s,t continuous integration bounds (times).

 Annualized volatility of Libor .

 const UTRRealMatrix& LiborFactorLoading::logLiborCovariationMatrix ( int p, int q, Real s, Real t ) const

The upper triangular half of the covariation matrix CV(p,q,s,t).

Parameters:
 p,q Libors . s,t continuous times .

The upper triangular half of the covariation matrix CV(t). This is the matrix needed for the drift part of the Libor process time step .

Parameters:
 t discrete time.

The upper triangular root R of the covariation matrix CV(t). This matrix is needed for the volatility part of the Libor process time step .

Parameters:
 t discrete time.

Rank r approximate root R of the covariation matrix CV(t). Best approximation , with R of rank at most r. This matrix is needed for the volatility part of the Libor process time step .

Parameters:
 t discrete time. r rank (number of factors).

 void LiborFactorLoading::factorAnalysis ( int p, int q, Real s, Real t, int r ) const
 Examines how dominant are the first r eigenvalues of the covariation matrix CV(p,q,s,t)=(C_ij) with entries This matrix is needed for the Libor time step s->t.

 Examines how dominant are the first r eigenvalues of the covariation matrix CV(t)=(C_ij) with entries This matrix is needed for the Libor time step .

 Test the roots of all logLiborCovariationMatrix(int t).

 Computes approximate rank r factorizations C(t)=R(t)R(t)' for all the matrices logLiborCovariationMatrix(int t) and prints the relative error.

 LiborFactorLoading* LiborFactorLoading::sample ( int n, int volType = VolSurface::JR, int corrType = Correlations::CS ) ` [static]`

Parameters:
 volType type of VolSurface (VolSurface::CONST, JR, M) corrType type of Correlation (Correlation::JR, CS)

 Message and fields.

## Member Data Documentation

 LiborFactorLoadingType LiborFactorLoading::flType` [protected]`

 int LiborFactorLoading::n` [protected]`

 RealArray1D LiborFactorLoading::delta` [protected]`

 RealArray1D LiborFactorLoading::T` [protected]`

 RealArray1D LiborFactorLoading::l` [protected]`

 RealArray1D LiborFactorLoading::x` [protected]`

 RealArray1D LiborFactorLoading::k` [protected]`
 VolSurface* LiborFactorLoading::vol` [protected]`
 Correlations* LiborFactorLoading::corr` [protected]`
 Correlations& LiborFactorLoading::rho` [protected]`
Generated on Mon Sep 22 02:16:33 2003 for Libor-Library by 1.3-rc3